1

As the title says I cannot shutdown or reboot from the GUI (when I say GUI I mean the one that loads after the startx command) after I am done. I can logout and reboot from command line but I cannot do it at once.

I have added another user, made him root and deleted pi user - if that matters - it appears the problem started after this change.

Can this be fixed?

I can post if you can tell me how or point me to where I should read so I can provide them.

Another problem I had after I created the new user was that the GUI taskbar was flashing and was unavailable for everything. After googling I fixed it by typing

sudo usermod -a -G audio <your_user>

P.S. I managed to reboot from SSH and from Ctrl+Alt+F2 but it still looks like I have a problem to fix. Please help.

Commands I used are:

>sudo adduser newuser 
>sudo visudo (to make him root) 
>sudo deluser -remove-home pi (to delete pi/remove pi user)

Note that I went through all this to harden my SSH because I want to use my raspberry pi over the net. Hence I will have to do it again after flashing and I'm afraid I will just reproduce the same problem.

  • How did you create the new user? Raspbian doesn't have a root login but there is a root user. It is probably going to be easier to just reflash your SD card and restart. – Milliways Sep 12 '15 at 11:54
  • Commands I used are: >sudo adduser newuser >sudo visudo (to make him root) >sudo deluser -remove-home pi (to delete pi/remove pi user) Note that I went through all this to harden my SSH because I want to use my raspberry pi over the net. Hence I will have to do it again after flashing and I m afraid I will just reproduce the same problem. – Karsus Sep 12 '15 at 12:26
0

It is still unclear exactly what you did. visudo does not make a user root.

Did you login as newuser before deleting pi?

You need to make the user a member of many groups to actually do anything try:-

for GROUP in adm dialout cdrom sudo audio video plugdev games users netdev input spi i2c gpio; do sudo adduser newuser $GROUP; done

I fear you have broken your installation if you deleted pi before login as newuser.

While I have posted the above, I do not see that changing user will "harden my SSH". There are better ways to do that, such as setting public/private keys and disabling password login.

  • You are right I probably broke my installation because I didn't know one should add a new user to groups. After researching I figured it out and did the following: >sudo adduser newuser >sudo visudo (to make him root) >sudo usermod -a -G adm,dialout,cdrom,sudo,audio,video,plugdev,games,users,netdev,input,indiecity newuser Then I checked that everything worked ok and I deleted user pi. Stuff continued to work fine. I know that private keys are safer for SSH hardening but I didn't want to dive into those waters yet. Anyway, fixed now that I know about user groups. Thank you for your help! – Karsus Sep 14 '15 at 22:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.