How To Create a Symbolic Link on Ubuntu

作者:Rui 发布时间:October 29, 2015 分类:Linux,CLOUD 浏览:407

The syntax of ln command is:

ln [options] <target file> [link name]

So, this command should work:

ln -sv /media/fileserver/anotherfile.ods /home/user/anotherfile.ods

The s option creates a symbolic link, if omitted a hard link will be created. v means "be verbose", i.e. ln will show what it's doing.

You could also cd to target's directory first:

cd /media/fileserver
ln -sv anotherfile.ods /home/user/anotherfile.ods

Or cd to destination directory:

cd /home/user/
ln -sv /media/fileserver/anotherfile.ods

If you omit the link name, target's name is used. The above command creates a link to /media/fileserver/anotherfile.ods in /home/user/anotherfile.ods.

How To Install Mysql on Ubuntu with Apt-Get

作者:Rui 发布时间:October 19, 2015 分类:Linux,CLOUD 浏览:357

Ubuntu 14.04 defaults to MySQL 5.5, but also has MySQL 5.6 available for installation from the universe archive. Installing 5.6 is as easy as specifying the version

Install Mysql

root@ubuntu1404:~# apt-get install mysql-server-5.6

Config Mysql

root@ubuntu1404:~# mysql -uroot -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 45
Server version: 5.6.16-1~exp1 (Ubuntu)Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> select version();
+---------------+
| version() |
+---------------+
| 5.6.16-1~exp1 |
+---------------+
1 row in set (0.00 sec)

Update: A slightly more detailed tutorial for this is available here.

Ubuntu12.04 下安装 Docker

作者:Rui 发布时间:October 7, 2015 分类:Linux,Docker,CLOUD 浏览:406

Docker容器现在越来越流行,加上微服务的形式的开发模式的越来越被接受,使得容器云更加重要。本文将记录如何在Ubuntu 12.04上安装Docker。

安装apt https和ca证书相关工具

 $ sudo apt-get update
 $ sudo apt-get install apt-transport-https ca-certificates

添加GPG key,并添加docker下载源地址

$ sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D

$ sudo sh -c 'echo "deb https://apt.dockerproject.org/repo ubuntu-precise main" >> /etc/apt/sources.list.d/docker.list'

$ sudo apt-get update

阅读剩余部分...

Ubuntu 12.04 LTS 中文输入法的安装

作者:Rui 发布时间:September 9, 2015 分类:Linux,CLOUD 浏览:436

安装 Ubuntu 12.04 着实费力一番功夫,老是在用 Ubuntu 来引导 Windows,结果 Ubuntu 倒是能用,一进入 Windows 就蓝屏,于是又重装 Windows 好几遍…直到后来认识了 EasyBCD 我才走上正途…

我装的是英文版的 Ubuntu12.04,如果安装中文版,会自动安装中文输入法,这篇文章也是为了以后重装 Ubuntu 做一个准备

废话不多说,进入正题:

第一步:安装语言包

进入 “System Settings”

1.png

找到 “Language Support” 那一项,点击进入
1.png

阅读剩余部分...

Ubuntu 14.04 国内更新源

作者:Rui 发布时间:September 9, 2015 分类:Linux,CLOUD 浏览:671

1、备份源

# sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak

2、编辑源文件/etc/apt/sources.list,并添加以下地址

# sudo gedit /etc/apt/sources.list

网易163源:

deb http://mirrors.163.com/ubuntu/ trusty main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ trusty-security main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ trusty-updates main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ trusty main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ trusty-security main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ trusty-updates main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ trusty-backports main restricted universe multiverse 

搜狐源:

deb http://mirrors.sohu.com/ubuntu/ trusty main restricted universe multiverse
deb http://mirrors.sohu.com/ubuntu/ trusty-security main restricted universe multiverse
deb http://mirrors.sohu.com/ubuntu/ trusty-updates main restricted universe multiverse
deb http://mirrors.sohu.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb http://mirrors.sohu.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://mirrors.sohu.com/ubuntu/ trusty main restricted universe multiverse
deb-src http://mirrors.sohu.com/ubuntu/ trusty-security main restricted universe multiverse
deb-src http://mirrors.sohu.com/ubuntu/ trusty-updates main restricted universe multiverse
deb-src http://mirrors.sohu.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb-src http://mirrors.sohu.com/ubuntu/ trusty-backports main restricted universe multiverse

oschina源:

deb http://mirrors.oschina.net/ubuntu/ trusty main restricted universe multiverse
deb http://mirrors.oschina.net/ubuntu/ trusty-backports main restricted universe multiverse
deb http://mirrors.oschina.net/ubuntu/ trusty-proposed main restricted universe multiverse
deb http://mirrors.oschina.net/ubuntu/ trusty-security main restricted universe multiverse
deb http://mirrors.oschina.net/ubuntu/ trusty-updates main restricted universe multiverse
deb-src http://mirrors.oschina.net/ubuntu/ trusty main restricted universe multiverse
deb-src http://mirrors.oschina.net/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://mirrors.oschina.net/ubuntu/ trusty-proposed main restricted universe multiverse
deb-src http://mirrors.oschina.net/ubuntu/ trusty-security main restricted universe multiverse
deb-src http://mirrors.oschina.net/ubuntu/ trusty-updates main restricted universe multiverse

3、 更新源索引,使新源生效

# sudo apt-get update

4、其他版本的源
只要将trusty 换成相应的版本的代号即可

更多国内源请参考:

http://wiki.ubuntu.org.cn/%E6%BA%90%E5%88%97%E8%A1%A8#Precise.2812.04.29.E7.89.88.E6.9C.AC