LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
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 10-27-2010, 08:12 AM   #1
Skullsoldier
Member
 
Registered: Oct 2010
Distribution: Debian
Posts: 32

Rep: Reputation: 0
installing/terminal/command promote Problems


Hey feels like that's more i have been using debian that's more problem I have confronted computer problems sow I need again help white a few things.

1. I have tried search from google a good instruction manual of how to use the command promote in debian, and only found bad ones, the reason why I am trying to find one is that I notice myself using the command promote all the time to install or doing anything.

2.how important is the command sudo in debian? Read instruction from here
3.[url] http://forums.debian.net/viewtopic.php?t=5127 [url] sow do I need to install sudo to use it? Got weird error when I am trying to execute commands to install t.ex [code]sudo apt-get install java[code] in return I get [code] administrator is not in the sudoers file. This incident will be reported.[code]
And when I am trying to install without the sudo command I get
E: Could not open lock file /var/lib/dpkg/lock - open (13 Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
I have tried to change permissions white chmod but it will return every time with permission denied

4.Then my last question is that when I wrote in terminal yes the command promote while spam white y why is it doing that?

Regards Skullsoldier
 
Old 10-27-2010, 08:55 AM   #2
alli_yas
Member
 
Registered: Apr 2010
Location: Johannesburg
Distribution: Fedora 14, RHEL 5.5, CentOS 5.5, Ubuntu 10.04
Posts: 559

Rep: Reputation: 92
Hi

Regarding point 3 - you are getting that error because you are not logged in as root and you're trying to execute a superuser command.

In order for sudo to work the user you're logged in as (I think administrator ) is not in your sudoers file (not too sure where that is configured on Debian but in Fedora/RHEL its in /etc/sudoers).
 
Old 10-28-2010, 01:46 AM   #3
Skullsoldier
Member
 
Registered: Oct 2010
Distribution: Debian
Posts: 32

Original Poster
Rep: Reputation: 0
Unhappy

Quote:
Originally Posted by alli_yas View Post
Hi

Regarding point 3 - you are getting that error because you are not logged in as root and you're trying to execute a superuser command.

In order for sudo to work the user you're logged in as (I think administrator ) is not in your sudoers file (not too sure where that is configured on Debian but in Fedora/RHEL its in /etc/sudoers).
I am able to get in to the /etc/sudoers file but when i am trying add after line

[code]root ALL=(ALL) ALL [code] add this line
[code]administrator ALL=(ALL) ALL [code]
when i write it out it just return: ERROR WRITING /etc/sudoers: Permission denied

i have also tried to log in as root but it's now allowing

Last edited by Skullsoldier; 10-28-2010 at 01:48 AM.
 
Old 10-28-2010, 01:57 AM   #4
Skullsoldier
Member
 
Registered: Oct 2010
Distribution: Debian
Posts: 32

Original Poster
Rep: Reputation: 0
just tried to make a new user and give it root acess from

SYSTEM->Administration->Users and Groups

and still i get the same error as before: ERROR WRITING /etc/sudoers: Permission Denied
 
Old 10-28-2010, 02:00 AM   #5
prayag_pjs
Senior Member
 
Registered: Feb 2008
Location: Pune - India
Distribution: Fedora,RedHat,CentOS,Gentoo
Posts: 1,138
Blog Entries: 4

Rep: Reputation: 147Reputation: 147
For adding a user to sudoer's list do this:

Code:
su -
give root password

you will get prompt like:#

do

Code:
#visudo
now if you want to add john to sudoer's list do this

Code:
john        ALL=(ALL)       ALL
save the file using wq

Note:donot edit /etc/sudoers but do visudo
 
Old 10-28-2010, 04:06 AM   #6
Skullsoldier
Member
 
Registered: Oct 2010
Distribution: Debian
Posts: 32

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by prayag_pjs View Post
For adding a user to sudoer's list do this:

Code:
su -
give root password

you will get prompt like:#

do

Code:
#visudo
now if you want to add john to sudoer's list do this

Code:
john        ALL=(ALL)       ALL
save the file using wq

Note:donot edit /etc/sudoers but do visudo
Thank you problem solved

still qurios that in terminal that when you write yes it spams y
 
Old 10-28-2010, 04:10 AM   #7
prayag_pjs
Senior Member
 
Registered: Feb 2008
Location: Pune - India
Distribution: Fedora,RedHat,CentOS,Gentoo
Posts: 1,138
Blog Entries: 4

Rep: Reputation: 147Reputation: 147
Thumbs up

Quote:
Originally Posted by Skullsoldier View Post
yes it spams y
It spams means what?
Post that output here and don't use short cuts instead of y write why
 
Old 10-28-2010, 06:16 AM   #8
Skullsoldier
Member
 
Registered: Oct 2010
Distribution: Debian
Posts: 32

Original Poster
Rep: Reputation: 0
here is the picture after i write it in the command line. if i scroll up it shows just blank white.
Attached Thumbnails
Click image for larger version

Name:	Untitled2.jpg
Views:	5
Size:	93.6 KB
ID:	5016  
 
  


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
How do I resize the terminal window from the command line in the gnome terminal QuIcKSpArK Linux - Newbie 5 04-21-2012 03:04 PM
[SOLVED] Make linux terminal transparent with terminal command? yooy Linux - Newbie 1 05-11-2010 04:24 AM
fdisk Terminal command problems - help appreciated AlestorJN DamnSmallLinux 3 06-25-2007 12:19 AM
problems installing limewire from terminal! randell6564 Ubuntu 1 05-29-2006 08:26 PM
Terminal command problems rogleale Linux - Newbie 3 06-21-2004 07:41 AM


All times are GMT -5. The time now is 12:34 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