Questions tagged [sudo]

sudo stands for Super User Do. It allows users to run programs with the security privileges of another user (if configured access permissions allow it), by default the superuser and is therefore prefixed before commands when full access to the operating system is required.

138 questions
20
votes
4 answers

startx: command not found

I am total newbie to Raspbian world and my problem is that I can't start the GUI because when I write: > startx I get back: bash-: startx command not found; using sudo returns the same error. I installed xterm, but still nothing. I started with…
V.Ruby
  • 209
  • 1
  • 2
  • 3
17
votes
6 answers

How to change user pi sudo permissions; how to add other accounts with different permissions?

Since I occasionally use my Pi over SSH, I have learned that it is dangerous to allow SSH to access sudo commands. Thus, I plan to turn off this permission in the near future. But, when I install packages I usually have to reboot. Currently, this is…
xxmbabanexx
  • 3,278
  • 7
  • 36
  • 56
14
votes
2 answers

How to play audio without being root (via sudo)?

In order to play audio (espeak or aplay for example) I have to be root (via sudo). How can I do those as just a regular user? Is there a group I must be a member of or do I have to change some permissions somewhere? Thanks.
kevin
  • 1,284
  • 3
  • 14
  • 26
13
votes
2 answers

Why do I have to `sudo`?

I've followed a couple of tutorials on my RPi and a lot of commands start with sudo; what does it mean and what does it do?
Alex Chamberlain
  • 15,638
  • 15
  • 69
  • 113
10
votes
3 answers

Can't access shared libraries when running with sudo

I'm trying to get a demo working writing PCM to the I2S; I've created a small demo program that gives an error when I run with the following command ./demo stereo_small.wav can't open /dev/mem So I run with the this command sudo ./demo…
Dog Ears
  • 2,027
  • 6
  • 19
  • 28
10
votes
4 answers

Disable sudo for user Pi (or require root password)

I'm pulling my hair out over this thing. Using Raspberian here. So I'm trying to restrict the Pi user from being able to use sudo without the root password. After heavy searching, I gave up on that, and now I'm trying to just disable all access to…
daviddavidson
  • 101
  • 1
  • 1
  • 3
10
votes
3 answers

Sudo permissions disaster

I just got a Pi-4. I'm not sure if I did something wrong while setting it up, but after getting it running I noticed that sudo commands required no passwords. I tried to change this, following some advice I found here: How to change user pi sudo…
Absurdistan
  • 111
  • 1
  • 4
9
votes
4 answers

Will Raspberry Pi OS update `sudo` to address a recent security vulnerability?

There has been some traffic online this year regarding an apparently substantial vulnerability in sudo that allows unauthorized privilege elevation - CVE-2021-3156. I've been checking sudo --version since I first heard of this, but after tonight's…
Seamus
  • 23,558
  • 5
  • 42
  • 83
7
votes
2 answers

Automatically run a program as root for GPIO?

I have a Raspberry Pi running Raspbian that I want to auto-login and then automatically run a program that uses the GPIO as root. I have auto-login working as per this website. What is the best way to run a program that needs GPIO? Is it adding the…
mirams
  • 3,928
  • 4
  • 19
  • 23
6
votes
1 answer

Pi3 "unable to resolve host" message

I have a message saying:"sudo: unable to resolve host (myhostname)" each time i write a command. My hostname do not contain any capital letter or number. thank you
Niz.Dam
  • 325
  • 3
  • 4
  • 11
6
votes
2 answers

Node.Js on raspbian not found with Sudo

I installed node.js according to this article . For this i downloaded a precompiled node.js arm-pi distributition and unzipped it cd /opt sudo wget http://nodejs.org/dist/v0.10.28/node-v0.10.28-linux-arm-pi.tar.gz After that i added the path to…
Boas Enkler
  • 215
  • 3
  • 7
6
votes
2 answers

Why does sudo not work in this case?

I was playing with the raspberry pi leds (How do I control the system LEDs using my software?) Interestingly, on my pi the following command fails: sudo echo heartbeat >/sys/class/leds/led0/trigger The error is bash: /sys/class/leds/led0/trigger:…
John Smith
  • 1,251
  • 3
  • 18
  • 27
5
votes
1 answer

How can I connect to the SFTP server with sudo via WinSCP?

I want to use WinSCP to connect to the Raspberry Pi standard SFTP server. I also need to have root access. How can I do this without logging in as root (using sudo)?
janssen-dev
  • 221
  • 1
  • 2
  • 8
5
votes
2 answers

sudo error - "Structure needs cleaning"

On my Pi Zero, if I issue a sudo su I get the following: $ sudo su sudo: error in /etc/sudo.conf, line 0 while loading plugin `sudoers_policy' sudo: /usr/lib/sudo/sudoers.so: Structure needs cleaning sudo: fatal error, unable to load plugins Any…
user3169632
  • 91
  • 1
  • 1
  • 5
5
votes
2 answers

Autorun Firefox on startup...grrrrrrr!

Long Story (Short): Okay, I've read all of the guides, questions etc I can find and it's still not happening. I can't get the browser to open its self up when the pi boots. Background: I'm following this…
Mr G Dwyer
  • 71
  • 1
  • 1
  • 6
1
2 3
9 10