visudo


Posted in:

การเพิ่มสิทธิ์ user ธรรมดาให้มีสิทธิพิเศษเหมือนเป็น root มีขั้นตอนดังนี้
1. เปิด terminal แล้วพิมพ์ visudo
2. ค้นหา root ALL=(ALL) ALL ด้วย /root ALL=(ALL) ALL หรือใช้ pageup/down เลื่อนลงไปด้านล่าง
3. เพิ่ม user ที่ต้องการในบรรทัดถัดไป เช่น

root ALL=(ALL) ALL
ีuser ALL=(ALL) ALL

4. Ctrl+x กด Y เพื่อบันทึก

อ้างอิง: http://www.pendrivelinux.com/2007/10/05/how-to-add-a-user-to-the-sudoers...

Other direct method.

หรือแก้โดยตรงที่ /etc/sudoers ได้ในทุกๆ Linux distro ครับ

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
  • Allowed HTML tags: <i> <center> <span> <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <br> <dt> <dd> <object> <embed> <hr> <img> <blockquote> <b> <u> <del> <div> <p> <table> <tr> <td> <font>

More information about formatting options