make help
Prerequisites : Ubuntu 12.04 LTS - 32bits, ex:lsb_release -a
Cross-compile : arm-linux-gnu-gcc 4.x.x
Shell Environment : bash , ex:sudo dpkg-reconfigure dash - select No
Tool Install :
1.genext2fs
2.mkimage [u-boot]
3.genromfs
4.make version 3.81
5.file version 5.0 upper
6.sudo apt-get install lzop
7.sudo apt-get install libncurses5-dev liblz4-tool xmlto cramfsprogs squashfs-tools
8.sudo apt-get install texinfo
9.sudo apt-get install openssl libssl-dev [version 1.0.1]
10.sudo apt-get install lib32z1 lib32ncurses5 lib32bz2-1.0
tar解壓失败:gzip: stdin: not in gzip format
****解壓縮:tar xvf -f filename.tar.bz2欲解壓縮的目錄*****
如出現上方解壓失敗 ,依紅色字體步驟方式。
2017年9月22日 星期五
2017年9月3日 星期日
bash script array sample
To declare an array in bash
Declare and an array called array and assign three values:
array=( one two three ) |
More examples:
files=( "/etc/passwd" "/etc/group" "/etc/hosts" ) limits=( 10, 20, 26, 39, 48) |
To print an array use:
printf "%s\n" "${array[@]}" printf "%s\n" "${files[@]}" printf "%s\n" "${limits[@]}" |
To Iterate Through Array Values
Use for loop syntax as follows:
for i in "${arrayName[@]}" do : # do whatever on $i done |
$i will hold each item in an array. Here is a sample working script:
#!/bin/bash # declare an array called array and define 3 vales array=( one two three ) for i in "${array[@]}" do echo $i done |
2017年8月17日 星期四
Windows10 & 2016 WOL
關於Windows10之後Wake on lan失效問題,請到下面連結下載
Win10 Auto Installation Program的realtek driver,安裝之後問題解決,也不用像其他資料寫得要改green ethernet或者Windows10的fast boot。
Win10 Auto Installation Program的realtek driver,安裝之後問題解決,也不用像其他資料寫得要改green ethernet或者Windows10的fast boot。
Win10 Auto Installation Program (SharedID:
1152921504607292454SId:1152921504626816921) 10.019 2017/7/27 10404k Global
| Win10 Auto Installation Program (SharedID: 1152921504607292454SId:1152921504626816921) | 10.019 | 2017/7/27 | 10404k | Global |
2017年8月8日 星期二
bash script sample
Bash Script 檔案及目錄是否存在
#!#!/bin/bashif [ -d "/path/to/dir" ]; then# 目錄 /path/to/dir 存在echo "Directory /path/to/dir exists."else# 目錄 /path/to/dir 不存在echo "Directory /path/to/dir does not exists."fi檢查檔案是否存在#!/bin/bash
if [ -f "/path/to/dir/filename" ]; then# 檔案 /path/to/dir/filename 存在echo "File /path/to/dir/filename exists."else# 檔案 /path/to/dir/filename 不存在echo "File /path/to/dir/filename does not exists."fi
2017年8月3日 星期四
dpkg-reconfigure dash
dpkg-reconfigure dash
Ubuntu / Debian 發行版本預設都使用 dash 作為 shell,但若使用 bash 習慣的人必定要執行此指令,choice No 將預設 shell 改為 bash!
dpkg-reconfigure locales
本土化語言設定。
dpkg-reconfigure tzdata
時區設定。
dpkg-reconfigure exim4-config
設定 Mail Transfer Agent(MTA)。
dpkg-reconfigure console-setup
設定 console 的字型、編碼等
dpkg-reconfigure gdm/lightdm
設定 display manager。目前 Ubuntu 預設為 lightdm,舊版為 gdm(gnome display manager。
dpkg-reconfigure openssh-server
重新產生 SSH server RSA 與 DSA key。
dpkg-reconfigure wireshark
安裝 wireshark 完成後,必須要使用 root 才可以順利擷取到網路介面封包,透過此命令可以設定一般使用者也可以正常操作
2017年8月1日 星期二
bash script sample
1.create a select menu in a shell script?
#!/bin/bash
PS3='Please enter your choice: '
options=("Option 1" "Option 2" "Option 3" "Quit")
select opt in "${options[@]}"
do
case $opt in
"Option 1")
echo "you chose choice 1"
;;
"Option 2")
echo "you chose choice 2"
;;
"Option 3")
echo "you chose choice 3"
;;
"Quit")
break
;;
*) echo invalid option;;
esac
done
2.create a Function in a shell script?
#!/bin/bash
function quit {
exit
}
function hello {
echo Hello!
}
hello
quit
echo foo
2017年7月4日 星期二
WakeMeOnLan
1.WakeMeOnLan此工具可以讓您藉由傳送網路喚醒(Wake-on-LAN,WOL)封包來遠端開機。當全部電腦開機時,此工具會掃描網路並收集電腦MAC位址,並將MAC位址資料儲存下來。事後,當電腦關機或在待機模式時,你可以使用儲存下來的電腦MAC位址來輕鬆選擇你想開啟的電腦。
【軟體名稱】:WakeMeOnLan
【軟體版本】:1.65
【軟體分類】:網路工具
【軟體介面】:繁體中文
【軟體性質】:免費軟體
【檔案大小】:434KB
【作業系統】:Windows
【官方網址】:http://www.nirsoft.net/utils/wake_on_lan.html
【免安裝版】 [按此下載]
使用前Enable Wake On LAN
MAC & IP EX:
00-xx-c0-xx-49-1b
192.168.x.x
【軟體名稱】:WakeMeOnLan
【軟體版本】:1.65
【軟體分類】:網路工具
【軟體介面】:繁體中文
【軟體性質】:免費軟體
【檔案大小】:434KB
【作業系統】:Windows
【官方網址】:http://www.nirsoft.net/utils/wake_on_lan.html
【免安裝版】 [按此下載]
使用前Enable Wake On LAN
MAC & IP EX:
00-xx-c0-xx-49-1b
192.168.x.x
訂閱:
文章 (Atom)