2010年12月6日 星期一
如何產生資料庫連結字串
昨天發現別人分享的方法!不錯用!
http://www.dotblogs.com.tw/dotjum/archive/2008/09/06/5310.aspx
2010年11月30日 星期二
2010年11月23日 星期二
該死的 dns cache~~
2010年11月18日 星期四
2010年7月18日 星期日
被另一個處理序鎖死並已被選擇作為死結的犧牲者
設想當資料有新增時,就檢查看是否有過舊的資料需要刪除
這也是相較於以往,以排程的方式,定期刪除過舊的資料,採用的新想法!
不過,看來並不是很理想! 在這樣的架構下,經常遭遇如下錯誤!
EOleException交易 (處理序識別碼 63) 在 鎖定 | 通訊緩衝區 資源上被另一個處理序鎖死並已被選擇作為死結的犧牲者。請重新執行該交易。
在停止此項Trigger後,就無再產生上述錯誤,
可是真正資源是如何的運用而產生死結,目前尚未明了!
2010年7月14日 星期三
2010年7月13日 星期二
2010年7月9日 星期五
變更索引名稱
2010年6月8日 星期二
tcpdump example
[root@host dump]# less capture.sh
MIP=172.17.100.41
MPORT=30002
FILE=/tmp/`date +'ap-%Y%m%d%H%M%S'`.pcap
tcpdump -i eth0 -s 0 -w $FILE tcp and port $MPORT
2010年6月7日 星期一
2010年5月27日 星期四
2010年5月5日 星期三
checktable可能自動修復一些系統問題
- 已正確連結索引、in-row、LOB 和資料列溢位資料頁面。
- 索引符合正確的排序順序。
- 指標一致。
- 每個頁面中的資料都是合理的,其中包括計算資料行。
- 頁面位移合理。
- 基底資料表的每個資料列在每個非叢集索引中都有相符的資料列,反之亦然。
- 資料分割資料表或索引中的每個資料列都在正確的資料分割中。
2010年4月13日 星期二
about D-Link DFL-210 console arp command
2010年4月8日 星期四
2010年4月6日 星期二
ARP announcements 機制
ARP announcements
因上架一台AscenLink 330 做 HA,發現 HA 生效換 MAC後,
D-Link DFL-210 竟然沒有刷新 ARP Cache,以致無法對外互動!
經過一番的查察,才找到如下文章!
結論:
AscenLink 330 的ARP announcements 機制不符慣例,
經調整DFL-210參數,放寬相關設限後,得以正常運作!
ARP may also be used as a simple announcement protocol. This is useful for updating other host's mapping of a hardware address when the sender's IP address or MAC address has changed. Such an announcement, also called a gratuitous ARP message, is usually broadcast as an ARP request containing the sender's protocol address (SPA) in the target field (TPA=SPA), with the target hardware address (THA) set to zero. An alternative is to broadcast an ARP reply with the sender's hardware and protocol addresses (SHA and SPA) duplicated in the target fields (TPA=SPA, THA=SHA).
An ARP announcement is not intended to solicit a reply; instead it updates any cached entries in the ARP tables of other hosts that receive the packet. The operation code may indicate a request or a reply because the ARP standard specifies that the opcode is only processed after the ARP table has been updated from the address fields.[4][5][6]
Many operating systems perform gratuitous ARP during startup. That helps to resolve problems which would otherwise occur if, for example, a network card was recently changed (changing the IP-address-to-MAC-address mapping) and other hosts still have the old mapping in their ARP caches.
Gratuitous ARP is also used by some interface drivers to effect load balancing for incoming traffic. In a team of network cards, it is used to announce a different MAC address within the team that should receive incoming packets.
ARP announcements can be used to defend link-local IP addresses in the Zeroconf protocol (RFC 3927), and for IP address takeover within high-availability clusters.
2010年2月4日 星期四
EXCEL 快速多段隱藏資料及展開資料
欄及列皆可使用
選取欲隱藏的列或欄-->資料-->群組及大網-->群組,此時該列或欄的次一列或欄,即為+,
欲展開資料列或欄,請直接點選左上之1或2即可。
不知簡易說明,是否能讓你明瞭,試試便知,
不用猛拉捲軸,好像還蠻好用的。
2010年1月12日 星期二
在excel中進行日期的加減運算
找不到如VB的函數 "dateadd",最後採如下方式處理,不知可否有更簡便的方式?
- A1="97/4/20"
- B1=date(year(a1)+13,month(a1),day(a1)) 可得 B1=2010/4/20
2010年1月4日 星期一
資料庫 restore 至它台主機後,無法登入!
在資料庫轉移時,從原主機「卸載(Detach)」資料庫檔案,並移至新主機「附加(Attach)」上去,在「新主機」沒有預先設定 Login 的情況下,資料庫中的 User 將無法刪除,也無法新增同名的 Login,相信有些人有遇到這樣的困擾過!
會 出現這個問題並不是 SQL Server 有 Bug,而是因為你每次建立的登入帳號都會在 SQL Server 中對應一個 SID,資料庫的「使用者」與「登入」的對應是用 SID 來比對的,所以你還原資料庫到另一台機器後,該資料庫中的使用者的 sid 無法比對到該主機 SQL Server 登入帳號中的 sid 所致,所以即便你自己新增了一個「登入」帳號,因為 SID 不一樣,所以也是沒有該資料庫的權限。
use gps;
--ALTER USER gps with login = gps;
EXEC sp_change_users_login 'Auto_Fix', 'gps', NULL;
執行後的結果敘述呈現如下:
- 使用者 'mtaxi' 的資料列將會藉由更新它和現有登入的登入連結來修復。
藉由更新使用者而修復的孤兒使用者數量為 1。
藉由新增新的登入再更新使用者而修復的孤兒使用者的數量為 0。 - 使用者 'maddr' 的資料列將會藉由更新它和現有登入的登入連結來修復。
藉由更新使用者而修復的孤兒使用者數量為 1。
藉由新增新的登入再更新使用者而修復的孤兒使用者的數量為 0。