LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-30-2015, 09:21 AM   #1
florek
LQ Newbie
 
Registered: Jun 2015
Posts: 1

Rep: Reputation: Disabled
problem with sudo on centos


Hello world,
I am installing webacula for web administration of bacula. I have encountered a problem while doing this command:
su -l apache -s /bin/sh -c "/usr/bin/sudo /opt/bacula/sbin/bconsole -n -c /opt/bacula/etc/bconsole.conf"

the console message shows this:
sudo: sorry, you must have a tty to run sudo

I don't know how to solve it. Please, can anyone helps me!!
Thank you,
 
Old 06-30-2015, 10:42 PM   #2
berndbausch
Senior Member
 
Registered: Nov 2013
Location: Tokyo
Distribution: Redhat/Centos, Ubuntu, Raspbian, Fedora
Posts: 1,692

Rep: Reputation: 353Reputation: 353Reputation: 353Reputation: 353
Quote:
Originally Posted by florek View Post
sudo: sorry, you must have a tty to run sudo
Google to the rescue!

A web search for your error comes back with a nice list of possible solutions. For example, this one seems to apply: http://www.cyberciti.biz/faq/linux-u...-haveattytorun.
 
Old 06-30-2015, 11:16 PM   #3
frankbell
LQ Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Debian, Mageia, and whatever VMs I happen to be playing with
Posts: 12,791
Blog Entries: 17

Rep: Reputation: 3317Reputation: 3317Reputation: 3317Reputation: 3317Reputation: 3317Reputation: 3317Reputation: 3317Reputation: 3317Reputation: 3317Reputation: 3317Reputation: 3317
I'm not sure it bears directly on your issue, but be aware that most distros, other than Ubuntu and its derivatives, do not share Ubuntu's sudo fetish; the sudoers file is not configured out of the box. CentOS is one of "most distros."

Most distros expect you to use su; if you absolutely must use sudo, you must configure sudoers accordingly using the visudo command.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] sudo: nano: command not found on CentOS DextrousDave Linux - Server 4 07-07-2013 07:26 AM
Location of Sudo in Centos ssaqib Linux - Newbie 7 11-08-2012 11:38 AM
[SOLVED] sudo in CentOS 6.2 Linux_Kidd Red Hat 3 05-05-2012 09:32 PM
LXer: Tutorial: Sudo on CentOS/Scientific Linux/RHEL LXer Syndicated Linux News 0 04-21-2012 01:12 AM
Problem with SUDO : sudo: pam_authenticate: Module is unknown cristoph_ Linux - Software 2 03-02-2009 08:12 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:24 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration