http://robotframework.org/
A keyword base test automation framework.
Setup on Windows:
1. Install Python 2.7
http://www.python.org/getit/
2. Install wxPython 2.8.12.1 (for RIDE)
http://sourceforge.net/projects/wxpython/files/wxPython/
3. Install robot framework (may use pip or easy_setup)
https://pypi.python.org/pypi/robotframework
4. Install RIDE
https://pypi.python.org/pypi/robotframework-ride
https://github.com/robotframework/RIDE/wiki/Installation-Instructions
5. Add PATH C:\Python27\Scripts
個人在學習Linux過程當中的個人筆記,提供個人及有需要的人查閱,若有錯誤歡迎提供指正,謝謝。 This Blog recorded notes about my learning Linux and provides myself and others reference. If there are any incorrect information, welcome to leave a message to correct me, Thanks.
2013年12月31日 星期二
2013年12月12日 星期四
How to PAUSE and CONTINUE a Linux process
Use kill command to send -STOP signal to pause a process and -CONT signal to continue it.
Example on CentOS6 Desktop:
1. Open a Terminal (name as T1) on Desktop and send "ps -aux | grep bash" to see how much bash in there.
2. Open another Terminal (name as T2) on Desktop and on T1 send "ps -aux | grep bash" to see process id of new created bash (T2)
3. On T1, send "kill -STOP" to pause T2
>T2 is hang
4. On T1, send "kill -CONT" to continue T2
>T2 is back to work
This is useful if a script is running on T2 and you want to pause it and continue it later
Reference:
http://tombuntu.com/index.php/2007/11/23/how-to-pause-a-linux-process/
Example on CentOS6 Desktop:
1. Open a Terminal (name as T1) on Desktop and send "ps -aux | grep bash" to see how much bash in there.
2. Open another Terminal (name as T2) on Desktop and on T1 send "ps -aux | grep bash" to see process id of new created bash (T2)
3. On T1, send "kill -STOP
>T2 is hang
4. On T1, send "kill -CONT
>T2 is back to work
This is useful if a script is running on T2 and you want to pause it and continue it later
Reference:
http://tombuntu.com/index.php/2007/11/23/how-to-pause-a-linux-process/
2013年12月5日 星期四
安裝Windows出現unable to create a new system partition
開機時移除USB,若需要Load Driver,等到跳出Load Driver畫面時在把USB stick插進去。
http://social.technet.microsoft.com/Forums/windows/en-US/9e18e169-f77e-4026-b22f-f602e670d55c/install-failure-unable-to-create-a-new-system-partition?forum=w7itproinstall
http://social.technet.microsoft.com/Forums/windows/en-US/9e18e169-f77e-4026-b22f-f602e670d55c/install-failure-unable-to-create-a-new-system-partition?forum=w7itproinstall
2013年11月28日 星期四
dhcpd6.conf & radvd.conf & ip6tables
1. On CentOS 6.4 or RHEL 6.4. install dhcp and radvd
>yum install dhcp radvd
2. Edit NIC config to add IPv6 address. /etc/sysconfig/network-scripts/ifcfg-eth0
IPV6INIT=yes
IPV6ADDR=3ffe:501:ffff:1::1/64
3. edit /etc/dhcp/dhcpd6.conf to assign address pool
subnet6 3ffe:501:ffff:1::/64 {
range6 3ffe:501:ffff:1::2 3ffe:501:ffff:1::1000
}
4. edit /etc/radvd.conf
interface eth0
{
AdvSendAdvert on;
MinRtrAdvInterval 30;
MaxRtrAdvInterval 100;
AdvHomeAgentFlag off;
AdvManagedFlag off; #M bit = 0
AdvOtherConfigFlag on; #O bit = 1
prefix fc00:1234:5678:9abc::/64
{
AdvOnLink on;
AdvAutonomous on;
AdvRouterAddr off;
};
};
5. add rule in /etc/sysconfig/ip6tables (before -j REJECT line)
-A INPUT -p udp -m udp -m multiport --ports 546 -j ACCEPT
-A INPUT -p udp -m udp -m multiport --ports 547 -j ACCEPT
6. set dhcpd6 radvd start when system up
>chkconfig radvd on
>chkconfig dhcpd6 on
Reference:
http://www.lijyyh.com/2012/05/dhcpv6ip-ciscolinux-isc-dhcpwindows.html
https://access.redhat.com/site/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Deployment_Guide/s1-dhcp_for_ipv6_dhcpv6.html
>yum install dhcp radvd
2. Edit NIC config to add IPv6 address. /etc/sysconfig/network-scripts/ifcfg-eth0
IPV6INIT=yes
IPV6ADDR=3ffe:501:ffff:1::1/64
3. edit /etc/dhcp/dhcpd6.conf to assign address pool
subnet6 3ffe:501:ffff:1::/64 {
range6 3ffe:501:ffff:1::2 3ffe:501:ffff:1::1000
}
4. edit /etc/radvd.conf
interface eth0
{
AdvSendAdvert on;
MinRtrAdvInterval 30;
MaxRtrAdvInterval 100;
AdvHomeAgentFlag off;
AdvManagedFlag off; #M bit = 0
AdvOtherConfigFlag on; #O bit = 1
prefix fc00:1234:5678:9abc::/64
{
AdvOnLink on;
AdvAutonomous on;
AdvRouterAddr off;
};
};
5. add rule in /etc/sysconfig/ip6tables (before -j REJECT line)
-A INPUT -p udp -m udp -m multiport --ports 546 -j ACCEPT
-A INPUT -p udp -m udp -m multiport --ports 547 -j ACCEPT
6. set dhcpd6 radvd start when system up
>chkconfig radvd on
>chkconfig dhcpd6 on
Reference:
http://www.lijyyh.com/2012/05/dhcpv6ip-ciscolinux-isc-dhcpwindows.html
https://access.redhat.com/site/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Deployment_Guide/s1-dhcp_for_ipv6_dhcpv6.html
2013年11月10日 星期日
Docker on Windows
Docker
目前只支援在Ubuntu下跑,若要在Windows下,可用VirtualBox搭配Vagrant使用
官方Install Document
1.首先把VirtualBox和Vagrant安裝起來
2. git clone docker and vagrant up
3. 用putty登入127.0.0.1:2222
(ubuntu vm的port 22被vagrant自動bind到host的port 2222)
default user/password 是 vagrant/vagrant
4. 登入後 基本使用教學
5. 之後就是在container的環境了,用apt-get可以安裝軟體,Alt+P & Alt+Q sequence可以跳回host(ubuntu vm)而不會結束container,跳host之後可用docker attach回去。
6. docker ps查看還在跑的container資訊,包括ID和port(docker run時用-p參數),docker ps -a可看全部
7. docker commit 可存下container成image,例如新安裝的軟體,方便下次直接run成新的container
8. 編寫Dockerfile可build新的image
9. docker images查看現在有的images
10. 若要讓vagrant bind ubuntu vm的port給host,在vagrant up之前要先set FORWARD_DOCKER_PORTS=True
(好像沒辦法正常up起來)
Best Practice
目前只支援在Ubuntu下跑,若要在Windows下,可用VirtualBox搭配Vagrant使用
官方Install Document
1.首先把VirtualBox和Vagrant安裝起來
2. git clone docker and vagrant up
git clone https://github.com/dotcloud/docker.git
cd docker
vagrant up
vagrant up之後會有一台ubuntu vm被開啟來,docker daemon就在上面執行3. 用putty登入127.0.0.1:2222
(ubuntu vm的port 22被vagrant自動bind到host的port 2222)
default user/password 是 vagrant/vagrant
4. 登入後 基本使用教學
sudo su
docker run -t -i ubuntu /bin/bash跑ubuntu這個image,產生一個container,執行/bin/bash並進入interactive shell
5. 之後就是在container的環境了,用apt-get可以安裝軟體,Alt+P & Alt+Q sequence可以跳回host(ubuntu vm)而不會結束container,跳host之後可用docker attach
6. docker ps查看還在跑的container資訊,包括ID和port(docker run時用-p參數),docker ps -a可看全部
7. docker commit
8. 編寫Dockerfile可build新的image
9. docker images查看現在有的images
10. 若要讓vagrant bind ubuntu vm的port給host,在vagrant up之前要先set FORWARD_DOCKER_PORTS=True
(好像沒辦法正常up起來)
Best Practice
2013年11月4日 星期一
MediaWiki 更改權限設定
http://www.mediawiki.org/wiki/Manual:Preventing_access
改LocalSettings.php裡的變數
$wgGroupPermissions['*']['edit'] = false;
防止沒登入的人編輯頁面
改LocalSettings.php裡的變數
$wgGroupPermissions['*']['edit'] = false;
防止沒登入的人編輯頁面
2013年10月24日 星期四
Python Google Chart
安裝pygooglechart時出現找不到module setuptools:
Note if you catch an error:"ImportError: No module named setuptools" please download http://peak.telecommunity.com/dist/ez_setup.py and install the setuptools.
參考資料:
http://pygooglechart.slowchop.com/
http://trac.edgewall.org/wiki/TracOnWindows/Python2.5
Note if you catch an error:"ImportError: No module named setuptools" please download http://peak.telecommunity.com/dist/ez_setup.py and install the setuptools.
參考資料:
http://pygooglechart.slowchop.com/
http://trac.edgewall.org/wiki/TracOnWindows/Python2.5
訂閱:
文章 (Atom)