logs archiveIRC Archive / Freenode / #centos / 2007 / January / 29 / 1
joe4444
is it possible to give a non-root user command completion for root commands?
doolph
Number5Plus, WHAT DO YOU WANT?
joe4444
for example, type "sudo usera[TAB]" to complete the 'useradd' command
range
joe4444: No, because the user doesn't have the same path as root does.
joe4444
range, can i simply give the user the same path as root?
range
If you absolutely want to ...
joe4444
is there a downside?
range
You normally cannot wreak havoc as a normal user, but with sudo and hastily completed path, you could if you get the wrong command.
Depends on the user, I'd say.
joe4444
it's for me, the lazy admin
hmm
it appears i already gave my admin user the same path as root
but i can't do 'usera[TAB]' or 'sudo usera[TAB]' with the admin user
         

range
Strange.
Works for me with stuff I have in the path.
joe4444
i can run useradd from any directory (get permission denied of course) but auto-complete doesn't work =/
Dyson
joe4444: this might depend on the shell you're using. I'm using ksh93 and completion for sudo never worked
joe4444
bash
Dyson
range: do you have any strange bash-completion stuff installed?
range
joe4444: That's easy.
You are not allowed to read the useradd binary.
As a normal user. That's why it doesn't show up, as the completion is still done in the usercontext.
joe4444
i see, so basically i can't accomplish this?
range
Dyson: No, but I never said that usera[TAB] worked, just stuff being in the path generally.
:)
Dyson
range: as I said... it doesn't work for me at all - neither with ksh93 nor with bash
range
Yes, I use bash_completion.
Dyson
yep. That's probably why it works for you
(Action) prefers alias <rootcmd>='sudo <rootcmd>' anyway
joe4444
Dyson, that does the trick =)
MACscr
im in the gui for centos 4.4, why cant i add a service to the service list if i know its already running
its showing up in "ps aux"
but not in the actual gui server list
alleycat
MACscr: what are you trying to do, detailed ?
MACscr
i setup openpbx and i would like to be able to set it up like a service so i can stop, start, etc, by simply typing in: service openpbx restart
etc
Dyson
MACscr: you have to provide an init-script for it
MACscr
hmm, ok, i guess i have to look into that
alleycat
MACscr: you must have a script in /etc/init.d which knows how to start/stop/whatever openbx
and this script must have a certain header (despite being a bash..)
MACscr
ah, ok, thanks for the tip
alleycat
which can be interpreted by chkconfig
chkconfig --add <service_name>
will (should) create some symlinks
similar to /etc/rc3.d/Smnopenbx
S-> start service
         

Hydr0p0nX
it's just a one or two line header indicating that 1.) chkconfig should look at it and 2.) which run levels the service should be running in
MACscr
found an init.d script for openpbx in their svn
got it working, thanks
i have no idea if im using kde or gnome, i think im using gnome, but how do i view files in the gui as root?
joe4444
open a terminal and then `su`
MACscr
ok, then what?
i dont want to use terminal to view and edit the files
joe4444
ls
oh
well i'm not familiar with any gui
Hydr0p0nX
then open konquer (or your file manager of choice) in super user mode
MACscr
right, how do i open it in super user mode
Hydr0p0nX
should have an option under system i think
I'm not sure with cent where it is but it would be in your K menu
alleycat
ALT-F2 -> select options -> select "run as a different user"
assuming you are using kde
puzzled
hi
MACscr
odd, thats not an option
i think im using gnome
lol =P
Hydr0p0nX
don't remember the option in gnome, but I'm sure it's there
ivx
hey, i am going to be getting a new server. if i take my hd out, and put it in a different computer, will centos get angry? or will it detect all the hardware and np
evil_steve
ivx: it depends how different the hardware is
if the hardware isn't supported by the kernel, you will probably need to add support, but if it's pretty vanilla it will probably just work
but your milage may vary
ivx
lol thanks
SubConsciousKill
Hey
Mrono
hi
SubConsciousKill
has any one ever set u0p shoutcast on CentOS
Mrono
no, but i was thinking about it
SubConsciousKill
i having Major issues getting any kind of server working on my dedi :(
Mrono
lets try it together
SubConsciousKill
i dont have a graphical interface
Mrono
like what
SubConsciousKill
its a server i have rented
i wanted gentoo
Mrono
have you tried nx machine?
SubConsciousKill
but they put CentOS
what is that?!?!/
Mrono
it runs an xwindow session over ssh
!freenx
dam, they don't have that here
http://www.nomachine.com/
SubConsciousKill
cheers loading up
Mrono
it's pretty simple
no server to install, just a client
SubConsciousKill
reallyh
downloadinfg bnow
now*8
Mrono
let me know if you need any help
SubConsciousKill
kk
its downloading! i hate slow internet / college :(
Server not installed NX access dissabled
Mrono
i'm just about to get you what you need
log in via ssh as root
you need to get a dsa key
SubConsciousKill
yaa
um... im not 2 great at linux :S
Mrono
give me a sec, i've got to remember where it is
SubConsciousKill
kk
Mrono
i found it somewhere and i don't remember
SubConsciousKill
lol
@Mrono you got a MSN account i cud add!?!?!
Mrono
on the ssh type 'nano /etc/nxserver/client.id_dsa.key'
SubConsciousKill
done
Mrono
copy the whole key
http://wiki.centos.org/FreeNX?highlight=%28freenx%29
that's where i'm getting this from
SubConsciousKill
oops i need the server installed :P
sorry for being n00b :S
Mrono
(Action) shoots self in head, so forgetful
Copy all the text (including the BEGIN DSA PRIVATE KEY and END DSA PRIVATE KEY lines. Press the Key... button, delete the text that is in there, and paste the client.id_dsa.key information from the server into the DSA Key text box (shown in yellow below}, then select Save.
the 'key' button is in the server config on nx machine
SubConsciousKill
um
ok
let me see
i cant find :S
Mrono
arn't you running centos?
right...
if you didn't already type yum install freenx
er yum install nx freenx
er..
SubConsciousKill
so Yum is like
Emerge in gentoo
Mrono
are you running centos?
SubConsciousKill
yaaa lol
i never used before
Mrono
so type yum install nx freenx
SubConsciousKill
doing
complete
Mrono
on the ssh type 'nano /etc/nxserver/client.id_dsa.key'
SubConsciousKill
kk
w@ i do with it???
misc--
I have an LVM on a disk with Centos which is working and booting fine and I'd like to make an exact copy of it to another disk, but the other disk has a different LVM name. What do I have to change to get it to boot properly? I've changed the fstab, grub, and the initrd, is there anything else? It can't mount proc either (I didn't copy /proc because I thought this is supposed to be created at bootup)
Mrono
Copy all the text (including the BEGIN DSA PRIVATE KEY and END DSA PRIVATE KEY lines.
SubConsciousKill
um..
kk
Mrono
now on your pc, click on the 'key' button in the server config
remove what's there and paste the code you got from your server
then click ok, and try to login
SubConsciousKill
server not insalled or NX access disable
d
Firebot
sorry to be off Topic, but is anyone here using squid_ldap_group ?
Mrono
did you copy the key over
SubConsciousKill
i cudnt see where 2 put it
« prev 1 2 3 4 5 6 7 next »