Tag: Linux

  • 使用密钥自动登录SSH(更新ssh-copy-id)

    【更新】 经lyxint提醒,发现了ssh-copy-id命令,第二步可以更简单的实现 ssh-copy-id -i ~/.ssh/id_rsa.pub username@hostname 其中username为用户名,hostname为服务器VPS的IP地址 1)在本机生成公钥密钥 ssh-keygen -t rsa 一路回车,选择默认路径即可,默认路径为~/.ssh/ 2)将本地公钥上传至服务器 cat ~/.ssh/id_rsa.pub|ssh username@hostname ‘sh -c “cat – >>~/.ssh/authorized_keys”‘ 其中username为用户名,hostname为服务器VPS的IP地址 3)ssh设置文件的几点说明(一般是默认即可) 路径:/etc/ssh/sshd_config 相关行: PubkeyAuthentication yes #开启公钥验证 #AuthorizedKeysFile %h/.ssh/authorized_keys #公钥的位置,建议使用默认路径

  • Android平台下FreePascal的交叉编译器

    0) Preface 0.1) The Operating System is Ubuntu 10.10 0.2) All the softwares are the latest stable version by April 12, 2011 1) Download the Source of Free Pascal Compiler The ‘fpc-2.4.2.source.tar.gz’ on http://sourceforge.net/projects/freepascal/files/Source/2.4.2/ 2) Install the fpc-source. Just extract it. The root folder of fpc-source for me is ‘/home/victorhu/fpc-source’ 3) Download the Arm-Eabi (Sourcery…

  • Linux/Ubuntu 10.04 + Nginx + MySql + php(FastCGI) + Phpmyadmin + WordPress

    新到手一台VPS,小试一下感觉不错,发帖留念。 注: 1、本文为完成之后根据回忆写成,如有问题欢迎指正 2、大部分文本操作直接在CLI下通过shell完成 0、准备工作 [shell]sudo apt-get update[/shell] 1、安装并开启Nginx [shell]sudo apt-get intsall nginx sudo /etc/init.d/nginx start #此时访问localhost如出现”Welcome to Nginx!”页面则表明安装成功[/shell] 2、安装mysql(会提示设置数据库密码) [shell]sudo apt-get install mysql-server mysql-client[/shell] 3、安装phpmyadmin并在虚拟主机根目录下建立软链接 [shell]sudo apt-get install phpmyadmin sudo ln -s /usr/share/phpmyadmin/ /var/www/heaptech.com/ #/var/www/heaptech.com 即为虚拟主机位置[/shell] 4、安装php [shell]sudo apt-get install php5 php5-cgi php5-mysql php5-curl php5-gd php5-idn php-pear php5-imagick php5-imap php5-mcrypt php5-memcache php5-mhash php5-ming php5-pspell…