pmk
Posts: 21
Joined: Wed Jun 20, 2012 5:27 pm

A little help required

Thu Aug 02, 2012 1:21 pm

I have just loaded raspbian using the installer on my 2 pi's but I have a few issues:

1) I can not use 'sudo' but have to log in as 'su' to do anything.

2) I can not find a desktop environment, 'startx' can not be found.

3) 'rpi-update' seems to work ok but throws out a few errors when it updates. Reboots ok tho.

Any help would be appreciated before I start build my apps on top of it.

Ta

bredman
Posts: 1415
Joined: Tue Jan 17, 2012 2:38 pm

Re: A little help required

Thu Aug 02, 2012 1:29 pm

Did you create a new user, or are you using the normal username "pi"?

User avatar
RaTTuS
Posts: 10330
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK

Re: A little help required

Thu Aug 02, 2012 1:33 pm

what errors?
does
cat /var/log/syslog
say anything intersting about errors
How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.html
WARNING - some parts of this post may be erroneous YMMV

1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe

pmk
Posts: 21
Joined: Wed Jun 20, 2012 5:27 pm

Re: A little help required

Sun Aug 05, 2012 1:31 pm

bredman wrote:Did you create a new user, or are you using the normal username "pi"?
I created a new user and not the 'pi' one.

pmk
Posts: 21
Joined: Wed Jun 20, 2012 5:27 pm

Re: A little help required

Sun Aug 05, 2012 1:33 pm

RaTTuS wrote:what errors?
does
cat /var/log/syslog
say anything intersting about errors
It is a very very long file but no information of errors in there.

Any idea where the startx is or do i need the load in new desktop ?

Nigel Day
Posts: 22
Joined: Sat Jun 16, 2012 2:15 pm

Re: A little help required

Sun Aug 05, 2012 6:33 pm

pmk wrote:
bredman wrote:Did you create a new user, or are you using the normal username "pi"?
I created a new user and not the 'pi' one.
To allow your new user to use sudo, you will have to update the file /etc/group. Look for the sudo line, and add a comma and your new username at the end.

To allow your new user to use sudo without haveing to quote a password, you will also need to edit the file sudousers, either alter the last line (which currently contains "pi ALL=(ALL) NOPASSWD: ALL") to replace the word pi with your user name, or add in a similar line using your user name. The latter approach means that the user pi can still use sudo without using a password, which you may (or may not) think a good thing.

bredman
Posts: 1415
Joined: Tue Jan 17, 2012 2:38 pm

Re: A little help required

Sun Aug 05, 2012 9:40 pm

Your problems are probably caused by not creating the new user correctly.

The correct method to define a new user is described at
http://elinux.org/RPi_Beginners#Create_ ... privileges

pmk
Posts: 21
Joined: Wed Jun 20, 2012 5:27 pm

Re: A little help required

Fri Aug 10, 2012 10:07 am

Thanks for the help, any idea where startx is ??

bredman
Posts: 1415
Joined: Tue Jan 17, 2012 2:38 pm

Re: A little help required

Fri Aug 10, 2012 10:28 am

pmk wrote:Thanks for the help, any idea where startx is ??
Try the command
/usr/bin/startx

If this works, it means that your launch paths are not set correctly.

rpural
Posts: 30
Joined: Fri Feb 24, 2012 2:30 pm
Location: Minnesota
Contact: Website

Re: A little help required

Fri Aug 10, 2012 11:41 am

There's more to a user than just a name. Do an "ls -al /home/pi" to see the hidden files there. I'm not sitting at mine, but a .profile or .bashrc may contain commands that set your $PATH variable which controls where you find programs, and not having this set would be why you aren't finding startx. Copy the .profile or .bashrc file from /home/pi to your home directory, log out and log back in, then try again. Thare are also many control files for the x-windows environment kept in hidden files, so you may not get the screen you're expecting....

Also, after creating your own userid, did you change the password for pi and root? If not, you've left a huge security hole in your system that anyone could come along and take advantage of...

shalo
Posts: 74
Joined: Tue May 08, 2012 7:25 pm

Re: A little help required

Fri Aug 10, 2012 11:57 am

pmk wrote:I have just loaded raspbian using the installer on my 2 pi's but I have a few issues:

1) I can not use 'sudo' but have to log in as 'su' to do anything.

2) I can not find a desktop environment, 'startx' can not be found.

3) 'rpi-update' seems to work ok but throws out a few errors when it updates. Reboots ok tho.

Any help would be appreciated before I start build my apps on top of it.

Ta
Just to clarify, because I suspect some/all of the replies here missed it. Are you using the installer as you have stated, or an image? My suspicion would be you just need to apt-get install lxde or whatever. (Also ensure the user is setup, per advice in this thread).

Or use an image file, the official one is probably going to be the simplest, especially if you require help in future.

Return to “Raspbian”