顯示具有 krimy0705 標籤的文章。 顯示所有文章
顯示具有 krimy0705 標籤的文章。 顯示所有文章

2010年7月8日

storage的硬體限制

Windows 2008 server 支援GPT 磁碟

 

(GPT) 磁碟分割樣式支援的大小高達 18 exabytes1000,000TB),每個磁碟最多可有 128 個磁碟分割。

 

ibmStorage DS3200來講,插滿122Tb SATA硬碟,可以到24TB

可在串接三台 EXP3000最多可以達到96.0TB SATA

 

2010年6月8日

FreeBsd的FTP上傳中文檔名會變亂碼

proftpd.conf 的設定檔內加上 UseEncoding local-charset client-charset

Ex:
繁體中文環境 UseEncoding UTF-8 Big5

 

 

如此用 不支援 UTF-8 編碼的 FTP Client 連上來, ProFTPD 就會自動轉碼成 client-charset

2010年5月31日

使用https 存取Gmail常發生ssl_error_access_denied_alert 的錯誤

使用https 存取Gmail常發生ssl_error_access_denied_alert 的錯誤,發現並不是系統的問題,又是Fortigate再搞鬼,檢查Firewall Protection Profile設定,設定以下Command即可已解決...
config firewall profile
Fortigate (profile) $ edit scan
Fortigate (scan) $ set https allow-ssl-unknown-sess-id
Fortigate (scan) $ end

2010年5月28日

yum 安裝發生"Header is not complete"

使用YUM install 或Yum update 每一個下載的RPM都發生同樣的Error  "Header is not complete",從系統或網路上始終找不出問題,後來想到可能是對外Firewall在搞鬼,拿掉Fortigate的Protection Profile後就可以正常使用Yum...

2010年5月20日

/tmp 中的檔案不見

Review 新公司的備份機制,發現備份的samba server中的檔案都會不見,而且是剛備份完是完整的,隔天檔案就不見了大半,後來檢查crontab job,發現dailly中有一個可疑的script "tmpwatch",原來這個script會定期刪掉720小時未存取的tmp檔案,前任網管又把備份的目錄設在/tmp,難怪會不見檔案,經一事長一智…..感謝前人的錯誤。

2010年5月18日

Router 1841 恢復預設值

 

新版的Router居然改了預設登入模式,預設帳號Cisco登入過後就失效了,我又臭屁3分鐘完成設定完後習慣就Reloadcisco帳號就無法登入,就變成都無法登入Console了,只能想辦法重設

重設方法如下:

Start a terminal session with the router via the Console port (telnet will not work for this). Physically reload the router, and from the console repeatedly hit the "Break" key, normally on the upper right hand side of the keyboard.

-You should now be in ROMMON mode. Type "confreg 0x2142" without quotes and hit Enter. Now type "reset" without quotes and hit Enter.

-Allow the router to restart, and hit "n" followed by Enter to stop the startup wizard.

-Type the following command sequence:

enable
conf t
config-register 0x2102
exit
write erase
<Enter key>
reload

The router will now boot normally, with a factory default configuration, even if you did not know any of the password(s) securing the router.

2010年5月17日

從待機或休眠中恢復時PCMCIA卡無法被識別,需重新插拔

從待機或休眠中恢復時PCMCIA卡無法被識別
Problem:


機器從待機或休眠中恢復時PCMCIA卡無法被識別,系統為Windows XP


Solution:


不需要更換硬件。請下載並安裝一個Hotfix補丁即可解決問題。鏈接如下:





如果系統已經安裝了Hotfix補丁但問題仍未修復,請將下述內容存為一個.reg註冊表文件,運行並導入即可:


Windows Registry Editor Version 5.00


[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\usb]


"USBBIOSx"=dword:00000001


"EnSoftRetry"=dword:00000001


"EnIdleEndPointSupportEX"=dword:00000001


"EnIdleEndPointSupport"=dword:00000001


"EnableIdleTimer"=dword:00000001

IBM X3650 M2 的網卡異常

轉換到新工作後,公司目前採購的主機幾乎都是IBM的,跟之前的HP或Dell不太一樣,還要慢慢瞭解IBM主機…

前幾天發生了一個狀況,主機有二片網路卡,都是內建的Broadcom NetXtreme II,其中一片網路卡會發生FTP 或遠端桌面有時會短暫無回應,但Ping都正常沒有miss,我抓取封包發現有時主機會idle,我懷疑是Layer 1或2 出了問題,嘗試換線換port都無效,更換新版的Driver後就恢復正常。
也許是這張網卡的功能太多了,有增加了許多功能IPMI,Checksum offload..等,基本的功能反而出錯了…

我處理的方式是更新新版的網路卡Driver (Broadcom NetXtreme II Driver v5.0.12 到 v5.2.14.0)
http://www-947.ibm.com/systems/support/supportsite.wss/docdisplay?lndocid=MIGR-5083635&brandind=5000008

mysql 的ROOT密碼忘記

先將mysql停止
#service mysqld stop
mysqld啟動並設為無登入控制模式
#mysqld_safe --skip-grant-tables&
登入mysql,注意喔,我沒輸入帳號密碼
#mysql
重新將mysql上的root密碼設定為1234
mysql> update mysql.user set password=PASSWORD('1234') where user='root';
讓剛剛的命令生效(修改或刪除帳號必須手動生效)
mysql> flush privileges;
離開mysql指令列
mysql> quit
重新啟動mysqld
#service mysqld restart

2008年10月2日

rpm 安裝時發生 Segmentation fault

rpm 安裝時發生 Segmentation fault
可能是RPM的db出了問題,
試試
rpm --rebuilddb 重修復db
rpm --initdb    重建立db
  

2008年9月15日

尋找Linux某一檔案內容的字串

find /home/user  -type f  -exec grep -l test {} \; 
-type f 只搜尋檔案(不然會find一堆目錄來比對) 
 
 

2008年5月15日

產生自動copy log的vb script

需求:自動move 5天前的log,避免主機硬碟滿
動作:move檔案,並紀錄move檔案的log

day3=date-5
year_value=right(datepart("yyyy",day3,1,1),2)
if datepart("m",day3,1,1)<10 then
month_value="0"&datepart("m",day3,1,1)
else
month_value=datepart("m",day3,1,1)
end if
select case month_value
case 1
mend=31
case 2
mend=28
case 3
mend=31
case 4
mend=30
case 5
mend=31
case 6
mend=30
case 7
mend=31
case 8
mend=31
case 9
mend=30
case 10
mend=31
case 11
mend=30
case 12
mend=31
end select

if datepart("d",day3,1,1)<10 then
day_value="0"&datepart("d",day3,1,1)
else
day_value=datepart("d",day3,1,1)
end if

'create batch file
Dim fso, log
Set fso = CreateObject("Scripting.FileSystemObject")
Set log = fso.openTextFile("d:\running\ct-ads2.bat",2,true)
log.WriteLine("echo *********************************** >>d:\log\hinet.log")
log.WriteLine("echo ct-act >>d:\log\hinet.log")
log.WriteLine("move \\192.168.24.34\ct-ads2-log\act\w3svc1\??"&year_value & month_value & day_value &".rar d:\log\ct-ads2-log\act >>d:\log\hinet.log")
log.WriteLine("move \\192.168.24.34\ct-ads2-log\act\w3svc1\??"&year_value & month_value & day_value &".rar d:\log\ct-ads2-log\act >>d:\log\hinet.log")
log.WriteLine("echo *********************************** >>d:\log\hinet.log")
log.Close


使用NTOP管理網路流量

管理頻寬使用量的常用工具
Openview
MRTG
sniffer,ethereal
Webtrend for Firewall
BandwidthD,Ntop
(以上我都有用,最常使用的是mrtg及ntop)

NTOP 的簡介
NTOP的發展原是為因對網路頻寬使用狀況的掌握,正如運用unix系統中的top指令以瞭解系統資源使用狀況一樣,可用圖形化的介面了解頻寬的使用情形.


NTOP 的運作原理
利用libpcap 的擷取封包功能將封包分析後存入資料庫,並將其結果輸出

NTOP的限制
只能用於區域網路內
無法跨SWITCH
硬體需求高,需要記憶體儲存擷取封包的資訊。

最近把google map及whois的功能新增進去,可反查ip的位置及owner。

2008年5月9日

最簡易的設定usb隨身碟成防止kavo病毒感染的方式

在隨身碟的根目錄下新增個資料夾,名稱是"autorun.inf",
避免kavo病毒寫入autorun.inf檔案。

2008年4月17日

限制公用無線AP進入公司

因開放二個無線AP在開放空間使用,
為方便使用所以無作安全設定,
我針對這個無線網路的network作限制,
讓這個network無法連到公司內部,
在core switch的設定如下...
interface vlan 12
ip access-group 110 in
access-list 110 deny ip 172.18.139.0 0.0.0.255 any log (限制無線網路的IP無法進入並記錄log)
access-list 110 permit ip any 192.168.0.0 0.0.255.255
access-list 110 permit icmp any 192.168.0.0 0.0.255.255