Ubuntu 18.04 教程
1 deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic main restricted universe multiverse 2 deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic main restricted universe multiverse 3 deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-updates main restricted universe multiverse 4 deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-updates main restricted universe multiverse 5 deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-backports main restricted universe multiverse 6 deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-backports main restricted universe multiverse 7 deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-security main restricted universe multiverse 8 deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-security main restricted universe multiverse 9 deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-proposed main restricted universe multiverse 10 deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ bionic main restricted universe multiverse deb http://mirrors.163.com/ubuntu/ bionic-security main restricted universe multiverse deb http://mirrors.163.com/ubuntu/ bionic-updates main restricted universe multiverse deb http://mirrors.163.com/ubuntu/ bionic-proposed main restricted universe multiverse deb http://mirrors.163.com/ubuntu/ bionic-backports main restricted universe multiverse deb-src http://mirrors.163.com/ubuntu/ bionic main restricted universe multiverse deb-src http://mirrors.163.com/ubuntu/ bionic-security main restricted universe multiverse deb-src http://mirrors.163.com/ubuntu/ bionic-updates main restricted universe multiverse deb-src http://mirrors.163.com/ubuntu/ bionic-proposed main restricted universe multiverse deb-src http://mirrors.163.com/ubuntu/ bionic-backports main restricted universe multiverse
deb https://mirrors.ustc.edu.cn/ubuntu/ bionic main restricted universe multiverse deb-src https://mirrors.ustc.edu.cn/ubuntu/ bionic main restricted universe multiverse deb https://mirrors.ustc.edu.cn/ubuntu/ bionic-updates main restricted universe multiverse deb-src https://mirrors.ustc.edu.cn/ubuntu/ bionic-updates main restricted universe multiverse deb https://mirrors.ustc.edu.cn/ubuntu/ bionic-backports main restricted universe multiverse deb-src https://mirrors.ustc.edu.cn/ubuntu/ bionic-backports main restricted universe multiverse deb https://mirrors.ustc.edu.cn/ubuntu/ bionic-security main restricted universe multiverse deb-src https://mirrors.ustc.edu.cn/ubuntu/ bionic-security main restricted universe multiverse deb https://mirrors.ustc.edu.cn/ubuntu/ bionic-proposed main restricted universe multiverse deb-src https://mirrors.ustc.edu.cn/ubuntu/ bionic-proposed main restricted universe multiverse
此处以清华源为例:
sudo gedit /etc/apt/sources.list
1 sudo apt-get update 2 sudo apt-get upgrate
sudo mkdir environment sudo mkdir java
sudo mv jdk1.8.0_171 /opt/environment/java/
sudo gedit ~/.bashrc
1 export JAVA_HOME=/opt/environment/jdk1.8.0_171 2 export CLASSPATH=.:${JAVA_HOME}/lib 3 export PATH=${JAVA_HOME}/bin:$PATH
wget -b https://dev.mysql.com/get/Downloads/MySQL-5.7/mysql-5.7.22-linux-glibc2.12-x86_64.tar.gz -o mysql-download.log
tail -f mysql-download.log
sudo mv mysql-5.7.22-linux-glibc2.12-x86_64 /opt/
sudo ln -s /opt/mysql-5.7.22-linux-glibc2.12-x86_64/ /opt/mysql
1 sudo apt-cache search libaio 2 sudo apt-get install libaio1
1 sudo groupadd mysql 2 sudo useradd -r -g mysql -s /bin/false mysql
1 cat > /opt/mysql/etc/my.cnf <<CNF 2 [mysqld] 3 basedir=/opt/mysql 4 datadir=/data/mysql 5 port=3306 6 socket=/data/mysql/mysql.sock 7 max_connections=260 8 pid-file=/data/mysql/mysql.pid 9 log-error=/data/mysql/error.log 10 CNF
1 sudo /opt/mysql/bin/mysqld ---defaults-file=/opt/mysql/etc/my.cnf --user=mysql –initialize-in 2 SQL> alter user root@localhost identified by ‘1‘;
sudo /opt/mysql/bin/mysqld --defaults-file=/opt/mysql/etc/my.cnf --user=mysql 2>&1 &
1 cat >~/.my.cnf <<EOF 2 [client]user=root 3 password=1 4 #在 /opt/mysql/etc/my.cnf 中有配置。用于本机进程通信 5 socket=/data/mysql/mysql.sock 6 EOF
1 [Desktop Entry] 2 3 Encoding=UTF-8 4 5 Name=Eclipse 6 7 Comment=Eclipse 8 9 #将下面这行改成自己的安装位置,最后一个eclipse不要擅自去掉,linux下eclipse的可运行文件没有后缀名 10 11 Exec=/opt/software/eclipse-jee-oxygen-3a-linux-gtk-x86_64/eclipse/eclipse 12 13 Icon=/opt/software/eclipse-jee-oxygen-3a-linux-gtk-x86_64/eclipse/icon.xpm 14 15 Terminal=false 16 17 StartupNotify=true 18 19 Type=Application 20 21 Categories=Application;Development
-javaagent:/opt/software/ideaIU-2018.1.2/idea-IU-181.4668.68/bin/JetbrainsCrack-2.7-release-str.jar
1 [Desktop Entry] 2 Encoding=UTF-8 3 Name=IntelliJ IDEA 4 Comment=IntelliJ IDEA 5 #因为idea在linux下的可运行文件是.sh方式,所以配置稍有不同 6 Exec=sh /opt/software/ideaIU-2018.1.2/idea-IU-181.4668.68/bin/idea.sh 7 Icon=/opt/software/ideaIU-2018.1.2/idea-IU-181.4668.68/bin/idea.png 8 Terminal=false 9 Type=Application 10 Categories=Developer; 11 Name[zh_CN]=IDEA
sudo gedit ~/.bashrc
1 export M2_HOME=/opt/environment/maven/apache-maven-3.5.3-bin/apache-maven-3.5.3 2 export PATH=${M2_HOME}/bin:$PATH
sudo apt-get install git
ubuntu18.04,因为依赖原因造成搜狗输入法安装失败,或者安装后无法启动等问题。
原文:https://www.cnblogs.com/lxc-2017/p/8991693.html