When execute sh script under linux, /bin/sh^M:bad interpreter:No such file or directory
Root Cause:
The file has been modify under windows.
#vim file name
:set ff
Check if fileformat=dos
Fixed:
:set ff=unix
:wq
Run script again.
2019年11月20日 星期三
2019年11月17日 星期日
Commad line flash BIOS/BMC fw(AMI code base)
Commad line flash BIOS/BMC fw
/Flash
Method
|
Command line (Local)
| |
EFI Shell
|
Windows
| |
BIOS
|
AfuEfix64.efi BIOS.bin /b /p /n /x
|
afuwinx64.exe BIOS.bin /b /p /n /x
|
BMC
|
socflash -s BMC.bin
|
yafuflash.exe -cd BMC.ima
|
FW /Flash
Method
| Command line (Local) |
Linux | |
BIOS | ./afulnx_64 BIOS.bin /b /p /n /x |
BMC | ./yafuflash -cd BMC.ima -vyes |
FW /Flash
Method
| Command line (Remote) |
Windows Client | |
BIOS |
Grantley:
yafuflash.exe -nw -ip [BMC_IP] -u username -p password -bios BIOS.bin
Purley:
yafuflash.exe -d 2-nw -ip [BMC_IP] -u username -p password BIOS.bin
|
BMC | yafuflash.exe -nw -ip [BMC_IP] -u username -p password -full BMC.ima |
2019年11月13日 星期三
Windows remote shutdown/reboot
Windows remote shutdown/reboot
Reboot:
net use \\Remote IP /user:administrator password
shutdown -m \\\\Remote IP -r -f -t 3
Shutdown
net use \\Remote IP /user:administrator password
shutdown -m \\\\Remote IP -s -f -t 3
2019年11月12日 星期二
How to enable/disable ethernet by command under windows
How to enable/disable ethernet by command under windows
disable
netsh interface set interface "Ehternet" disabled
enable
netsh interface set interface "Ethernet" enabled
2019年11月11日 星期一
Reset BMC username/password by ipmitool locally
Reset BMC username/password by ipmitool locally
ipmitool raw 0x6 0x45 0x02 0x72 0x6F 0x6F 0x74 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
ipmitool raw 0x6 0x47 0x02 0x02 0x70 0x77 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
ipmitool raw 0x6 0x47 0x02 0x01
ipmitool raw 0x6 0x43 0x93 0x02 0x04 0x00
ipmitool raw 0x6 0x40 0x03 0x82 0x84
ipmitool raw 0x6 0x40 0x03 0x42 0x44
User will set to "root"
Password is "pw"
2019年11月6日 星期三
How to write a linux script with loop
How to write a linux script with loop
While true
do
XXXX (Command1)
sleep 2
XXXX (Command2)
done
------------------------------------------
Add count with color
------------------------------------------
Add count with color
While true
do
XXXX (Command1)
sleep 2
XXXX (Command2)
echo -e "\033[40;32m "This is $count times." \033[0m"
count =$(($count+1))
done
訂閱:
文章 (Atom)
-
[Office] 自從您上次存檔後檔案 (filename.xls) 可能已由另一位使用者變更 當您嘗試將 Microsoft Excel 活頁簿儲存到網路伺服器時,如果該伺服器正在執行例如 Services for Macintosh 的中繼服務,或是在開啟活頁簿時出現...
-
Use AMISCE tool to update BIOS configuration under linux Test fucntion without change dump file 1.Copy SCELNX_64 to Linux_Flash folder 2...
-
I would like to thank you for all your support during the past years and hope that you will continue to extend the same to my replacement, ...