软件更新
-----------------------------------------------------------------
进入系统后,什么也不要做,先去更新软件;如果网速慢的话,可以稍后更新
更多请参考
https://blog.csdn.net/weixin_38359296/article/details/79084979
log.csdn.net/weixin_38359296/article/details/79084979
刚开始会有系统更新的命令,选择更新,这需要大概1小时的时间
软件安装
------------------------------------------------------------
sudo rm /var/cache/apt/archives/lock
sudo rm /var/lib/dpkg/lock
sudo rm /var/cache/apt/archives/lock-frontend
sudo rm /var/lib/dpkg/lock-frontend
apt install vim
apt install net-tools
sudo apt-get install screen
sudo apt-get install git ntpdate
apt install git
sudo apt-get install tcl tk expect
sudo apt-get install libldap2-dev
apt-get install libsasl2-dev
sudo apt-get install unixodbc unixodbc-dev
apt-get install libmysqlclient-dev
apt install python3-pip
pip3 install mysqlclient
ubantu sudo 免密码
------------------------------------------------------------
root@db:~# cat /etc/sudoers.d/black
%black ALL=(ALL) NOPASSWD:ALL
不锁屏
---------------------------------------
settings-->Privacy-->Automatic Screen Lock--> OFF
或者
下三角-->个人用户--> UNLOCK
vmware tools安装
---------------------------------------
点击标签安装vmware tools,复制到一个目录,解压tar.gz
sudo ./
挂载新磁盘
----------------------------------------------------------mkfs -t ext4 /dev/nvme0n1p4
mkdir /disk
mount -t ext4 /dev/nvme0n1p4
/disk
vim /etc/fstab
/dev/nvme0n1p4 /disk ext4 defaults 0 0
挂载windows文件目录到ubantu -- vbox
------------------------------------
https://www.cnblogs.com/linjiqin/p/3615477.html
挂载点设置为disk
mkdir /disk
mount -t vboxsf disk /disk
要想自动挂载的话,可以在/etc/fstab中添加一项
disk /disk vboxsf rw,gid=100,uid=1000,auto 0 0
5、卸载的话使用下面的命令:
sudo umount -f /disk
挂载windows文件目录到ubantu -- vmware
------------------------------------
ll /mnt/hgfs/
rsync -rltDv /mnt/hgfs/disk/* /disk/
ubuntu远程桌面连接windows系统
------------------------------------------------
sudo apt-get install rdesktop
开始从ubuntu启动了,仅需要一条命令:
rdesktop -f -a 16 114.67.105.113
就ok了。
有1 个“严重”的问题,登录后屏幕的上方没有退出全屏的按钮,怎么退出全屏?
Ctrl+Alt+Enter 可以退出全屏。
退出全屏后如果再次全屏进入windows xp?
再次Ctrl+Alt+Enter就可以了。
用法: rdesktop[options] server[:port]
命令参数常用的有:
-u用户名
-p密码
-n客户端主机名(显示windows任务管理器中的连接客户端名)
-g桌面大小( 宽* 高)[也可以用 x(小写的X)]
-f全屏模式,从全屏模式切换出来按Ctrl+Alt+Enter
-a连接颜色深度(最高到16位),一般选16才会显示真彩色(window7支持32位)
-0数字0表示连接上windows控制台,等效mstsc/console命令
例子:
1、在全屏模式下用真彩色、客户端名为connection、用户名pan连接192.168.0.100控制台
$rdesktop-f -a 16 -n connection -u pan -0 192.168.0.100
2、以800*600(W*H)窗口大小、真彩色、用户名pan、打开远程端口为16453的192.168.0.101控制台
$rdesktop -g 800*600 -a 16 -u pan -0 192.168.0.101:16453
安装远程桌面
---------------------------------------
https://baijiahao.baidu.com/s?id=1619271691270163095&wfr=spider&for=pc
安装 tightvncserver、xrdpsudo
apt install tightvncserver xrdp
安装xubuntu-desktop
sudo apt install xubuntu-desktop
mkdir /opt/soft
mkdir /opt/soft/{django,java,mysql,python}
chown -R black.black /opt/
小企鹅五笔输入法
sudo apt-get install fcitx-table-wubi
安装后重启系统
右上角的输入法图标-->restart-->config
重启一下ubuntu系统 -->进入输入法管理-->Manage Installed Language --> keyboard input method system:fcitx -->重启系统后就可以看到语言小图标了
配置 --> 点击+号 --> 添加wubi输入法,注意窗口下方的上下箭头,可以调换输入法的顺序,将新添加的输入法调换到第一行
配置 -->Global Config-->配置默认的输入法切换命令组合
切换-->custom switch key
xshell连接ubantu服务器
---------------------------------------------------------------
sudo apt-get install openssh-server
sudo service ssh restart
sudo apt install net-tools
登录显示
Welcome to Ubuntu 19.04 (GNU/Linux 5.0.0-16-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
安装wps
wps下载网址:http://community.wps.cn/download/
关于Ubuntu16.04中WPS不能输入中文的问题:参考
http://blog.csdn.net/duxu24/article/details/52711693
sudo dpkg -i wps-office_11.1.0.8392_amd64.deb
ubantu安装python3
简易安装
---------------------------------------------------------------------------------
sudo apt install python3 # version 3.7.3-1, or
sudo apt install python # version 2.7.16-1
sudo apt install python-minimal # version 2.7.16-1
更改默认值,python默认为Python2,现在修改为Python3,谁的值高谁优先
sudo update-alternatives --install /usr/bin/python python /usr/bin/python2 100
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 150
apt install python-pip
apt install python3-pip
其他安装方式
-------------------------------------------------
请注意,系统自带的python千万不能卸载!
输入命令
sudo add-apt-repository ppa:jonathonf/python-3.7
按Enter确认
输入命令sudo apt-get update
输入命令sudo apt-get install python3.6
数据库安装
========================================================
mysql
-------------------------------------------------------------------
sudo apt-get install mysql-server
修改配置文件
vim /etc/mysql/my.cnf
[mysqld]
server-id = 100 # 不限制具体数值
log_bin = mysql-bin
binlog_format = row
character-set-server=utf8
需要以root用户启动
/etc/init.d/mysql start
mysql -uroot -p
Enter password:
默认密码为空
用户创建
create user 'automng'@'%' ;
GRANT ALL PRIVILEGES ON *.* TO 'automng'@'%' identified by 'Automng_123' WITH GRANT OPTION;
create user 'automng'@'127.0.0.1' ;
GRANT ALL PRIVILEGES ON *.* TO 'automng'@'127.0.0.1' identified by 'Automng_123' WITH GRANT OPTION;
create user 'automng'@'localhost' ;
GRANT ALL PRIVILEGES ON *.* TO 'automng'@'localhost' identified by 'Automng_123' WITH GRANT OPTION;
flush privileges;
create user 'root'@'127.0.0.1' ;
GRANT ALL PRIVILEGES ON *.* TO 'root'@'127.0.0.1' identified by '123456' WITH GRANT OPTION;
flush privileges;
/etc/init.d/mysql restart
mysql -uautomng -pAutomng_123
alias root="mysql -uroot -p123456"
redis
-------------------------------------------------------------
sudo apt-get install redis-server
vim /etc/redis/redis.conf
# bind 192.168.1.100 10.0.0.1
bind 0.0.0.0
/etc/init.d/redis-server start
redis-cli
127.0.0.1:6379>
mongodb
----------------------------------------------------------------------------
sudo apt-get install mongodb
vim /etc/mongodb.conf
bind_ip = 0.0.0.0
/etc/init.d/mongodb start
netstat -tunlp |grep mongo
tcp 0 0 127.0.0.1:27017 0.0.0.0:* LISTEN 16750/mongod
/etc/init.d/mongodb restart
# mongo
MongoDB shell version v3.6.8
connecting to: mongodb://127.0.0.1:27017
cetons
https://www.imooc.com
https://www.imooc.com/article/22072
Ubuntu18.04安装Docker
************************************************************************************************
简易安装
-------------------------------------------------------------------
sudo apt install docker.io
systemctl unmask docker.service
systemctl unmask docker.socket
systemctl start docker.service
sudo systemctl start docker
sudo systemctl enable docker
docker -v
code
===============================
ubantu下载
https://code.visualstudio.com/docs/?dv=linux64_deb
dpkg -i
Eclipse
===============================
JAVA
export JAVA_HOME=/opt/app/jdk8/
export CLASSPATH=.:$JAVA_HOME/lib/tools.jar:$JAVA_HOME/lib/dt.jar:$CLASSPATH
export PATH=$JAVA_HOME/bin:$PATH
source /etc/profile
java -version
elipse
下载linux版本即可
eclipse背景色设置https://jingyan.baidu.com/article/d5a880eb6c4f7813f147ccef.html
eclipse配置go所需要的linux版的godef/gocode/guru https://download.csdn.net/download/tpfbx/12084070
2019-12版本随之升级的有CodeMix插件,可以尝试一下