[ask] user login selain root
#11
(02-02-2012, 01:40 AM)konspirasi Wrote: owh hehe sama seperti ane dulu Tongue

save nya tekan ESC dulu, abis itu ketik :wq (write quit) trus ENTER

ko gk bisa ya om?
ane udah bikin gini
Quote:# User privilege specification
root ALL=(ALL) ALL
[username ane] ALL=(ALL) ALL

abis itu ane ikutin kata om konspirasi ketik :wq (write quit) trus enter
tapi responnya malah "E172: Only one file name allowed"...
tu knp ya om?
atau ane ada salah ketik?

Angry Angry

#12
hmmm klo gitu emang harus cm satu aja, coba masukin grupnya aja yg di sudoers, coba dari awal aja...

Code:
adduser username admin

perintah diatas itu buat username dengan grup admin

setelah itu..
Code:
cp /etc/sudoers /etc/sudoers.backup
vim /etc/sudoers

kita backup dulu sudoersnya, buat jaga2 Big Grin

udah di vim? seharusnya seperti ini tampilannya:
Quote:# /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
#

Defaults env_reset

# Host alias specification

# User alias specification

# Cmnd alias specification

# User privilege specification
root ALL=(ALL) ALL

# Allow members of group sudo to execute any command after they have
# provided their password
# (Note that later entries override this, so you might need to move
# it further down)
%sudo ALL=(ALL) ALL
#
#includedir /etc/sudoers.d

# Members of the admin group may gain root privileges
%admin ALL=(ALL) ALL

klo udah persis seperti diatas keluar aja dari vim trus ubah mode sudoers, standarnya sih 0440
Code:
chmod 0440 /etc/sudoers

reboot aja supaya yakin Big Grin

#13
(02-03-2012, 12:39 AM)konspirasi Wrote: klo udah persis seperti diatas keluar aja dari vim trus ubah mode sudoers, standarnya sih 0440
Code:
chmod 0440 /etc/sudoers

reboot aja supaya yakin Big Grin

perintah "chmod 0440 /etc/sudoers" itu mksudnya biar apa ya om?
ane udah ikutin,tapi stlah perintah chmod itu gk ada respon apa2 om..
pas ane cb login ke user baru,gnomenya masih error..

#14
itu permission bro .. klo ane sarankan tidak perlu om taro user di ALL privilege .. mending om bikin user di bawah sudoers.. langsung terminal terus bikin gini ..

root@bt : mkdir /home/[nama-user] ---> nntinya buat home folder user baru
root@bt : useradd [nama-user] -G admin -d /home/[nama-user]
root@bt : passwd [nama-user] --> masukin password buat user baru ...

cek user sudah bekerja dengan baik atau belum

root@bt : su [nama-user]

atau reboot terus login dengan user baru ...

kalau mau melakukan perintah2 root tinggal masukan ..

sudo [ perintah-cmd/shell ]

FOLLOW @DutaLinux
for more question and sharing about security and Opensource only

#15
@mas zee : mas [nama-user], pas login harus ada "[]" ?

#16
(02-04-2012, 01:41 AM)zee eichel Wrote: itu permission bro .. klo ane sarankan tidak perlu om taro user di ALL privilege .. mending om bikin user di bawah sudoers.. langsung terminal terus bikin gini ..

root@bt : mkdir /home/[nama-user] ---> nntinya buat home folder user baru
root@bt : useradd [nama-user] -G admin -d /home/[nama-user]
root@bt : passwd [nama-user] --> masukin password buat user baru ...

cek user sudah bekerja dengan baik atau belum

root@bt : su [nama-user]

atau reboot terus login dengan user baru ...

kalau mau melakukan perintah2 root tinggal masukan ..

sudo [ perintah-cmd/shell ]

ane udah coba cara ini berhasil masuk ke gnome-nya (walaupun smpet panik krna error..heheh), tapi tetep gk bisa akses ke aplikasi ky vlc,chromium ya om..?

trus, kalo di terminal,bukan nama user yg muncul,tapi malah "sh-4.1#" ..
emang bgitu atau ada yg salah ya om zee???

#17
(02-03-2012, 12:39 AM)konspirasi Wrote: hmmm klo gitu emang harus cm satu aja, coba masukin grupnya aja yg di sudoers, coba dari awal aja...

Code:
adduser username admin

perintah diatas itu buat username dengan grup admin

setelah itu..
Code:
cp /etc/sudoers /etc/sudoers.backup
vim /etc/sudoers

kita backup dulu sudoersnya, buat jaga2 Big Grin

udah di vim? seharusnya seperti ini tampilannya:
Quote:# /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
#

Defaults env_reset

# Host alias specification

# User alias specification

# Cmnd alias specification

# User privilege specification
root ALL=(ALL) ALL

# Allow members of group sudo to execute any command after they have
# provided their password
# (Note that later entries override this, so you might need to move
# it further down)
%sudo ALL=(ALL) ALL
#
#includedir /etc/sudoers.d

# Members of the admin group may gain root privileges
%admin ALL=(ALL) ALL

klo udah persis seperti diatas keluar aja dari vim trus ubah mode sudoers, standarnya sih 0440
Code:
chmod 0440 /etc/sudoers

reboot aja supaya yakin Big Grin


Semangat pak Confused

pengguna baru Imoet

#18
(02-07-2012, 01:14 AM)anaknakal24 Wrote: trus, kalo di terminal,bukan nama user yg muncul,tapi malah "sh-4.1#" ..
emang bgitu atau ada yg salah ya om zee???

Milih shell harus yang /bin/bash

tipe shell : /etc/shells

lakukan modifikasi user ...

usermod -s /bin/bash [nama-user]

jgn lupa kasi password

passwd [nama-user]

FOLLOW @DutaLinux
for more question and sharing about security and Opensource only






Users browsing this thread: 1 Guest(s)