m0tzo
Posts: 4
Joined: Tue Feb 24, 2015 3:35 am

Pi 2 Sudo Issue

Sat Mar 07, 2015 4:10 pm

Hi All,

First time poster, but have regularly read stuff on the fourm. This time I'm posting as before I return my Pi 2 I thought I'd seek advice here first.

Got my Pi 2 shortly after launch with intention of replacing my original Pi B (also got shortly after launch).

I was using a customised version of Raspian for my Ham Radio hobby which had a couple of extra programs added, and worked fine on B model. I downloaded same image and installed on MicroSD card (Verbatim 16Gb class 10) and did updates for it on the old Pi.

Upon running on new Pi I loaded the terminal and ran "sudo apt-get update" but the cursor moves to next line and nothing happens. Closed the terminal and tried again. Same thing. Ran "top" and that worked. Trying different commands even "sudo top" just hangs with nothing happening.

I thought maybe was version I was running so also tried a clean Raspian download and then the Noobs version and same result.

So it was suggested by friend to check power. I used a tablet mains lead that came with Asus Transformer, so should have more than enough power and same result.

Finally today was able to get a try a new SanDisk Ultra 16Gb class 10 MicroSD card.

I am still having the same Problem. Same card in adaptor in the old B works fine and as expected.

Hopefully I've covered everything and I am thinking I need to return, but am posting in last small hope it's something silly I've not tried or expected.

Paul

User avatar
Jednorozec
Posts: 809
Joined: Sun Nov 24, 2013 2:17 pm
Location: Deposit, NY

Re: Pi 2 Sudo Issue

Sat Mar 07, 2015 4:41 pm

What happens if you run "sudo su"?
The most important leg of a three legged stool is the one that's missing.
It's called thinking. Why don't you try it sometime?

m0tzo
Posts: 4
Joined: Tue Feb 24, 2015 3:35 am

Re: Pi 2 Sudo Issue

Sat Mar 07, 2015 6:26 pm

Hi Jednorozec, tried on old Pi first so knew what should happen.

"sudo su" also just hangs and does nothing.

User avatar
Jednorozec
Posts: 809
Joined: Sun Nov 24, 2013 2:17 pm
Location: Deposit, NY

Re: Pi 2 Sudo Issue

Sat Mar 07, 2015 7:00 pm

Are you logged in as the pi user and have you made any changes to the pi user? If you haven't made any changes then I can't think of any reason that sudo wouldn't work when everything else seems to be working.

You could try setting a root password and then using su instead of sudo. Boot on your old Pi and then type "sudo passwd" and then type a new password twice.
The most important leg of a three legged stool is the one that's missing.
It's called thinking. Why don't you try it sometime?

User avatar
joan
Posts: 15085
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Pi 2 Sudo Issue

Sat Mar 07, 2015 7:04 pm

Why do you think the image you downloaded (from where?) should work on the Pi 2? If it is directly accessing the gpios the software will need to be updated for the Pi 2.

m0tzo
Posts: 4
Joined: Tue Feb 24, 2015 3:35 am

Re: Pi 2 Sudo Issue

Sat Mar 07, 2015 9:54 pm

Hi joan,

As I mentioned in my first post, after the updated version failed I downloaded fresh versions of Raspbian and then Noobs after I received my Pi 2. Also I never said I was using GPIO, and I'm not.

User avatar
SteveDee
Posts: 343
Joined: Thu Dec 29, 2011 2:18 pm
Location: Sunny Southern England
Contact: Website

Re: Pi 2 Sudo Issue

Sun Mar 08, 2015 11:56 am

m0tzo wrote:Hi joan,

As I mentioned in my first post, after the updated version failed I downloaded fresh versions of Raspbian...
Very, very odd!

Some suggestions:-
Run: whereis sudo
...should get something like: sudo: /usr/bin/sudo /usr/lib/sudo /usr/share/man/man8/sudo.8.gz

Try running (say) file manager as root by typing in terminal: gksu pcmanfm

Make sure root is listed when you run: cat /etc/passwd

Go to Menu > Preferences > Users & Groups
...not sure what we are looking for here, but you should see Group sudo with GroupID 27 and members includes pi

Try to boot without loading desktop.

I can't think of anything else at the moment.

m0tzo
Posts: 4
Joined: Tue Feb 24, 2015 3:35 am

Re: Pi 2 Sudo Issue

Sun Mar 29, 2015 11:02 pm

@SteveDee Sorry didn't get a chance to try, but I have a reason.

I emailed CPC and explained my issue (partly by showing this thread). They gave me an RMA number and waiting on replacement.

Slight hiccup when I left MicrSD card in it, but was found and they are returning it.

Once it's back I'll try the version I was going to use originally and report back.

metalj
Posts: 212
Joined: Sat Feb 07, 2015 11:56 pm

Re: Pi 2 Sudo Issue

Sun Mar 29, 2015 11:14 pm

I had a similar issue and realized after much fustration that I wasn't connected to the internet.
Backspace 28 times :)

LeoJr2015
Posts: 11
Joined: Sun Mar 01, 2015 4:25 pm

Re: Pi 2 Sudo Issue

Mon Mar 30, 2015 2:27 pm

metalj wrote:I had a similar issue and realized after much fustration that I wasn't connected to the internet.
what does connecting to the internet have to do with sudo?? :shock:

metalj
Posts: 212
Joined: Sat Feb 07, 2015 11:56 pm

Re: Pi 2 Sudo Issue

Mon Mar 30, 2015 3:18 pm

The person said sudo apt-get update. You can't apt-get stuff stuff from the internet without the internet. Well you probably could but when you think you're online but not it seems like something's wrong.
Backspace 28 times :)

troombatzia
Posts: 501
Joined: Fri Jun 29, 2012 4:27 pm

Re: Pi 2 Sudo Issue

Mon Mar 30, 2015 6:32 pm

sudo bash and you become root.
English isn’t my first language, so please excuse any mistakes.

Return to “General discussion”