Monthly Archives: November 2012

lame-servers: info: error (network unreachable) resolving

Latest BIND DNS server by default has the IPV6 DNS resolving enabled. Any DNS query will caused the program to also resolve IPV6 IP although the host server or client is not IPV6 enable or capable Workaround / Solution : … Continue reading

Posted in Linux | Tagged , , | 2 Comments

HTML – center an image vertically & horizontally

<body> <table id=”table-foo”> <tr><td> <img sr=”foo.png” /> </td></tr> </table> </body> <style type=”text/css”> html, body { height: 100%; } #table-foo { width: 100%; height: 100%; text-align: center; vertical-align: middle; } #table-foo img { display: block; margin: 0 auto; } </style>

Posted in Others | Tagged , | 1 Comment

Cacti – manually rebuild poller cache

php -q /usr/share/cacti/cli/rebuild_poller_cache.php

Posted in Linux | Tagged | Leave a comment

Disk /dev/md0 doesn’t contain a valid partition table

That’s normal for a software raid array – the mdX arrays don’t contain partition tables as hda/sda, hdb/sdb etc. The partition table is written on the physical drives themselves. [root@backup /]# fdisk -l Disk /dev/sda: 2000.3 GB, 2000398934016 bytes 255 … Continue reading

Posted in Linux | Tagged | Leave a comment

Exchange save/export mailbox to pst file

New-MailboxExportRequest -Mailbox “alice.cooper” -IncludeFolders “#Contacts#” -FilePath  \\server_name\temp\alice_cooper.pst -ExcludeDumpster   (exports only Contacts folder ) New-MailboxExportRequest -Mailbox alice.cooper -FilePath  \\server_name\temp\alice_c.pst  (export user’s mailbox) Get-MailboxExportRequestStatistics -Identity: alice.cooper\MailboxExport  – to see the export status # Export all e-mails between date range ( Including Sent … Continue reading

Posted in Exchange | Leave a comment

Exchange – Pipeline not executed because a pipeline is already executing

Exchange Error: Pipeline not executed because a pipeline is already executing. Pipelines cannot be executed concurrently. This error is caused because the Windows PowerShell remoting feature doesn’t support more than one pipeline running at the same time. To resolve this … Continue reading

Posted in Exchange | 3 Comments

Replacing Failed Raid1 Drive (mdadm)

To identify if a RAID Array has failed look at the string containing [UU]. Each “U” represents an healthy partition in the RAID Array. If you see [UU] then the RAID Array is healthy. If you see a missing “U” … Continue reading

Posted in Linux | Tagged | Leave a comment

Remove spaces from files

find . -name ‘* *’ | while read file; do target=`echo “$file” | sed ‘s/ /_/g’`; echo “Renaming ‘$file’ to ‘$target’”; mv “$file” “$target”; done

Posted in Linux | Tagged | 1 Comment

Mysql – Remove firts/last characters from a string

Remove firts or last characters from a string: UPDATE `table` SET `column` =  TRIM(leading  ‘1c3’  FROM `column`); #first characters (1c3) UPDATE `table` SET `column` =  TRIM(trailing  ‘xyz’  FROM `column`); #last characters (xyz)

Posted in MySQL | Leave a comment

Exchange – add/remove access to all calendars by ‘Cutom Attribute’

add-MailboxFolderPermission -Identity  user1:\Calendar -User user2 -AccessRights AvailabilityOnly Exchange:  Access to all Calendars for Alice Get-mailbox -Filter {(CustomAttribute1 -eq “Employee”)} | ForEach-Object {Add-MailboxFolderPermission $_”:\Calendar” -User alice.cooper -AccessRights Reviewer} -confirm:$false    —  No prompter Remove Alice’s calendar permissions from all calendars : $Mailboxes … Continue reading

Posted in Exchange | Leave a comment