Navigation

    蓝鲸ROS机器人论坛

    • Register
    • Login
    • Search
    • Categories
    • Tags
    • Popular
    ROS交流群
    ROS Group
    产品服务
    Product Service
    开源代码库
    Github
    官网
    Official website
    技术交流
    Technological exchanges
    激光雷达
    LIDAR
    ROS教程
    ROS Tourials
    深度学习
    Deep Learning
    机器视觉
    Computer Vision

    让ubuntu普通用户支持不输密码直接shutdown命令关机

    技术交流
    ubuntu 关机命令
    1
    1
    3567
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • frank
      frank last edited by frank

      修改/etc/sudoers文件

      sudo gedit /etc/sudoers
      #然后增加下列指令
      %xiaoqiang ALL = NOPASSWD: /sbin/shutdown  #将xiaoqiang换成自己的用户名
      #保存后退出
      

      现在可以关机试试

      sudo shutdown  -h now
      

      会发现不用输密码了

      1 Reply Last reply Reply Quote 0
      • 1 / 1
      • First post
        Last post
      Copyright © 2015-2023 BlueWhale community