linux中的一些常用指令

  • 更新更新源

    sudo apt-get update
  • Ubuntu完全卸载python

    • 卸载python2.7
      sudo apt-get remove python2.7
    • 卸载依赖
      sudo apt-get remove --auto-remove python2.7
    • 清除python2.7
      sudo apt-get purge python2.7
      or
      sudo apt-get purge --auto-remove python2.7
  • pip3的安装、升级、卸载

    • 安装
      sudo apt-get install python3-pip
    • 升级
      sudo pip3 install --upgrade pip
    • 卸载
      ````bash
      sudo apt-get remove python3-pip
      ```
  • 设置ubuntu支持远程连接

    • 给服务器安装一个openssh-server

      sudo apt-get install openssh-server
    • adb连接mumu模拟器

      adb connect 127.0.0.1:7555
  • mongodb相关:

    • 创建超级管理员用户
      db.createUser(
      {
      user: "fengshu",
      pwd: "fengshu361",
      roles: [ { role: "userAdminAnyDatabase", db: "admin" } ]
      }
      )
    • 创建普通用户
      db.createUser(
      {
      user: "fengshu01",
      pwd: "fengshu789",
      roles: [ {role:"readWrite",db:"AcountState"} ]
      }
      )
    • 配置文件
      vim /etc/mongo.conf    
  • 重装ubuntu桌面

    sudo apt-get install ubuntu-desktop
本作品采用《CC 协议》,转载必须注明作者和本文链接
讨论数量: 0
(= ̄ω ̄=)··· 暂无内容!

讨论应以学习和精进为目的。请勿发布不友善或者负能量的内容,与人为善,比聪明更重要!