Author Topic: Off topic ... Some help with Linux please  (Read 14505 times)

Offline Julian

  • Administrator
  • Oil baron
  • *******
  • Posts: 6391
    • Used Cooking Oil Collection website
  • Location: East Surrey, UK.
Off topic ... Some help with Linux please
« on: December 09, 2013, 09:45:47 PM »
Aimed primarily at James (if you are around), but if anyone else can help I'd be very grateful.

It's probably a very simple problem but being a complete novice at Linux, and a Muppet at IT generally, I'm really struggling.

I’ve bought the electronics for this 3D printer and, I believe, worked out how it all hooks up.  To run it I need some software which is open source and readily available with what look to be very clear and concise instruction as follows ....

-----------------------------------------------

 Installing for all users

If you want RepRap to be available system-wide to all users, you will need to log in as the superuser to install it.

Assume you downloaded reprap-nnnnnn-yyyymmdd.zip into the directory /xxx/yyy. Move to the directory /usr/local, then unpack it:

Code: [Select]
# cd /usr/local
# unzip /xxx/yyy/reprap-nnnnnn-yyyymmdd.zip

Then move to the /usr/local/bin directory and create a short shell script called reprap using your favourite text editor (gedit in the example).

Code: [Select]
# cd /usr/local/bin
# gedit reprap

Copy and paste these three lines into the script, then save it:

Code: [Select]
#!/bin/sh
cd /usr/local/reprap-nnnnnn-yyyymmdd
./reprap

(Don't forget to replace the nnnnnn and the yyyymmdd with the right strings for your distribution file.)

Finally, set execute permission on the file:

Code: [Select]
# chmod 755 reprap
Any user will now be able to run the software just by typing the command "reprap".

There is a RepRap teardrop symbol in the file /usr/local/reprap-nnnnnn-yyyymmdd/reprap-icon.png which people can use if they add the program to their desktop or task-bar as a clickable executable. The program is /usr/local/bin/reprap .

If you want to save space, you can now delete the distribution .zip file:

Code: [Select]
# rm /xxx/yyy/reprap-nnnnnn-yyyymmdd.zip
-----------------------------------------------

There appear to be some additional instructions for 64 bit systems (which mine is), but that's another bridge to cross later perhaps.  For completeness this is the page where the instructions are located ...

http://reprap.org/wiki/Installing_RepRap_on_your_computer

I've managed to get the unzipped main directory located in  usr/local and some how (I've tried so many things) managed to create the reprap file in usr/local/bin.  I've run the chmod 755 reprap command which I beleive makes the file accessible to all, but each time I try and run the program using the reprap command, I get a "Permission denied" warning and nothing happens.

I've managed to find a command which lists permissions for bin and the result is ...

Code: [Select]

root@julian-HP:/usr/local/bin# ls -l
total 8
-rwxrwxr-x 1 root root 62 Dec  9 01:00 reprap
-rw-r--r-- 1 root root 62 Dec  9 00:49 reprap~

I'm now at the point of pulling out clumps of hair, any help (phrased as if talking to a 10 year old) would be greatly appreciated.





Used Cooking Oil Collection website ... http://www.surreyusedcookingoilcollection.palmergroup.co.uk

Offline Rotary-Motion

  • Wiki Editor
  • Oil baron
  • *******
  • Posts: 2875
Re: Off topic ... Some help with Linux please
« Reply #1 on: December 09, 2013, 09:54:02 PM »
sack it go windows weeeeeeeeeeeee

 ;D

Offline therecklessengineer

  • Administrator
  • Oil obsessive
  • *****
  • Posts: 648
Re: Off topic ... Some help with Linux please
« Reply #2 on: December 09, 2013, 09:58:12 PM »
Yup, sounds like a permissions problem.

What happens if you type

Code: [Select]
sudo reprap

Offline Rotary-Motion

  • Wiki Editor
  • Oil baron
  • *******
  • Posts: 2875
Re: Off topic ... Some help with Linux please
« Reply #3 on: December 09, 2013, 09:59:51 PM »
im trying to contact someone into this but had no reply as of yet

Offline Julian

  • Administrator
  • Oil baron
  • *******
  • Posts: 6391
    • Used Cooking Oil Collection website
  • Location: East Surrey, UK.
Re: Off topic ... Some help with Linux please
« Reply #4 on: December 09, 2013, 10:04:54 PM »
sack it go windows weeeeeeeeeeeee

 ;D

I have that load of dog excrement that is windows 8 and Im not convinced that it will run with that.  It's a case of having committed to Linux, I really need to brave it out (I might learn something in the process).

I managed to find the answer to the non-operational wireless card ... you had to "blacklist the very card you were trying to install!  All very logical really.
Used Cooking Oil Collection website ... http://www.surreyusedcookingoilcollection.palmergroup.co.uk

Offline Julian

  • Administrator
  • Oil baron
  • *******
  • Posts: 6391
    • Used Cooking Oil Collection website
  • Location: East Surrey, UK.
Re: Off topic ... Some help with Linux please
« Reply #5 on: December 09, 2013, 10:07:21 PM »
Yup, sounds like a permissions problem.

What happens if you type

Code: [Select]
sudo reprap

Thanks, James.

This is the result (what I've been getting for three evenings)

Code: [Select]
julian@julian-HP:~$ sudo reprap
[sudo] password for julian:
/usr/local/bin/reprap: 3: /usr/local/bin/reprap: ./reprap: Permission denied
julian@julian-HP:~$
Used Cooking Oil Collection website ... http://www.surreyusedcookingoilcollection.palmergroup.co.uk

Offline therecklessengineer

  • Administrator
  • Oil obsessive
  • *****
  • Posts: 648
Re: Off topic ... Some help with Linux please
« Reply #6 on: December 09, 2013, 10:48:46 PM »
could you do an
Code: [Select]
ls -l in
Code: [Select]
/usr/local/ please?

Offline Julian

  • Administrator
  • Oil baron
  • *******
  • Posts: 6391
    • Used Cooking Oil Collection website
  • Location: East Surrey, UK.
Re: Off topic ... Some help with Linux please
« Reply #7 on: December 09, 2013, 10:50:38 PM »
Code: [Select]
julian@julian-HP:~$ cd /usr/local/
julian@julian-HP:/usr/local$ ls -l
total 40
drwxrwxr-x 2 root root 4096 Dec  9 01:00 bin
drwxr-xr-x 2 root root 4096 Feb 13  2013 etc
drwxr-xr-x 2 root root 4096 Feb 13  2013 games
drwxr-xr-x 2 root root 4096 Feb 13  2013 include
drwxr-xr-x 2 root root 4096 Dec  6 23:43 java
drwxr-xr-x 3 root root 4096 Feb 13  2013 lib
lrwxrwxrwx 1 root root    9 Jun 27 19:27 man -> share/man
drwxrwxrwx 4 root root 4096 Dec  9 00:23 reprap
drwxr-xr-x 2 root root 4096 Feb 13  2013 sbin
drwxr-xr-x 7 root root 4096 Feb 13  2013 share
drwxr-xr-x 2 root root 4096 Feb 13  2013 src
julian@julian-HP:/usr/local$

Used Cooking Oil Collection website ... http://www.surreyusedcookingoilcollection.palmergroup.co.uk

Offline julianf

  • Wiki Editor
  • Grand Gunge Master
  • ******
  • Posts: 1388
  • Location: Devon
Re: Off topic ... Some help with Linux please
« Reply #8 on: December 09, 2013, 11:05:19 PM »
its a long time since ive used linux, but the second file on the list -

-rw-r--r-- 1 root root 62 Dec  9 00:49 reprap~


is not executable.

if it needs to be, chmod 777
For custom cnc cut instrument panels, see - http://www.thebeast.co.uk

Collections website - http://www.devon-used-cooking-oil-collection.co.uk

Offline Julian

  • Administrator
  • Oil baron
  • *******
  • Posts: 6391
    • Used Cooking Oil Collection website
  • Location: East Surrey, UK.
Re: Off topic ... Some help with Linux please
« Reply #9 on: December 09, 2013, 11:11:09 PM »
its a long time since ive used linux, but the second file on the list -

-rw-r--r-- 1 root root 62 Dec  9 00:49 reprap~


is not executable.

if it needs to be, chmod 777

Yes the reprap file needs to be executible.  Not sure why two files are showing up as there is only one in the directory, but I've tried
Code: [Select]
chmod 755 reprap
and

Code: [Select]
chmod 777 reprap
Numerous times to no avail.
Used Cooking Oil Collection website ... http://www.surreyusedcookingoilcollection.palmergroup.co.uk

Offline therecklessengineer

  • Administrator
  • Oil obsessive
  • *****
  • Posts: 648
Re: Off topic ... Some help with Linux please
« Reply #10 on: December 09, 2013, 11:11:59 PM »
Ok, first hurdle is to get the software running, then make it accessible to all users later (do you really need that?)

So to undo what you've done so far:

Code: [Select]
sudo rm -r /usr/local/reprap
sudo rm -r /usr/local/bin/rep*

(I think....might need tweaking)

Then

Code: [Select]
cd ~/
wget https://github.com/reprap/release/blob/master/reprap-mendel-20120421.zip
unzip reprap-mendel-20120421.zip

Then try running it:

Code: [Select]
cd reprap-mendel-20120421
./reprap

I think the permission denied message is a red herring. It's been installed as root and you're trying to run it as Julian.
« Last Edit: December 09, 2013, 11:14:54 PM by therecklessengineer »

Offline Julian

  • Administrator
  • Oil baron
  • *******
  • Posts: 6391
    • Used Cooking Oil Collection website
  • Location: East Surrey, UK.
Re: Off topic ... Some help with Linux please
« Reply #11 on: December 09, 2013, 11:19:16 PM »
Ok thanks, I'll plough through that lot, give me a mo.
It doesn't have to be accessible to all ... I'm the only user anyway, I just wanted the quickest way to get to the software and all users seemed logical.
Used Cooking Oil Collection website ... http://www.surreyusedcookingoilcollection.palmergroup.co.uk

Offline therecklessengineer

  • Administrator
  • Oil obsessive
  • *****
  • Posts: 648
Re: Off topic ... Some help with Linux please
« Reply #12 on: December 09, 2013, 11:22:02 PM »
Making something available to all is more difficult in linux. The above essentially moves the executables to your home directory - only you can access them there.

Offline julianf

  • Wiki Editor
  • Grand Gunge Master
  • ******
  • Posts: 1388
  • Location: Devon
Re: Off topic ... Some help with Linux please
« Reply #13 on: December 09, 2013, 11:30:23 PM »
isnt he logged on as root?

(my days of linux ended arround red hat 6 time - for years i had a box doing 'stuff' that had no gui, and not even a monitor or keyboard attached - but its all very hazy now!)
For custom cnc cut instrument panels, see - http://www.thebeast.co.uk

Collections website - http://www.devon-used-cooking-oil-collection.co.uk

Offline Julian

  • Administrator
  • Oil baron
  • *******
  • Posts: 6391
    • Used Cooking Oil Collection website
  • Location: East Surrey, UK.
Re: Off topic ... Some help with Linux please
« Reply #14 on: December 09, 2013, 11:31:33 PM »
This is the last bit, seems to say it can't find things ....

j
Code: [Select]
ulian@julian-HP:~$ cd ~/
julian@julian-HP:~$ wget https://github.com/reprap/release/blob/master/reprap-mendel-20120421.zip
--2013-12-09 23:49:00--  https://github.com/reprap/release/blob/master/reprap-mendel-20120421.zip
Resolving github.com (github.com)... 192.30.252.128
Connecting to github.com (github.com)|192.30.252.128|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 24360 (24K) [text/html]
Saving to: `reprap-mendel-20120421.zip'

100%[======================================>] 24,360      --.-K/s   in 0.02s   

2013-12-09 23:49:00 (1.40 MB/s) - `reprap-mendel-20120421.zip' saved [24360/24360]

julian@julian-HP:~$ unzip reprap-mendel-20120421.zipcd reprap-mendel-20120421
unzip:  cannot find or open reprap-mendel-20120421.zipcd, reprap-mendel-20120421.zipcd.zip or reprap-mendel-20120421.zipcd.ZIP.
julian@julian-HP:~$ ./reprap
bash: ./reprap: Is a directory
julian@julian-HP:~$

I've obviously rushed into this without knowing the basics, but when you say running it as root and julian, is that indicated by the text in front of the @ sign?  If so I'm sure I've tried in both.

I did try copying the unzipped directory to home, making a bin directory and putting the reprap file in the but that didn;t seem to work ... most probably something I cocked up though.
Used Cooking Oil Collection website ... http://www.surreyusedcookingoilcollection.palmergroup.co.uk