วันศุกร์ที่ 14 มกราคม พ.ศ. 2565

Powershell - Check client status

$servers = Get-Content C:\Temp\serverlist.txt
$collection = $()
foreach ($server in $servers)
{
    
        $status = @{ "ServerName" = $server; "TimeStamp" = (Get-Date -format "dd-MM-yyyy hh:mm") }
        if (Test-Connection $server -Count 1 -ea 0 -Quiet)
    {
        $status["Results"] = "Up"
    }
    else
    {
        $status["Results"] = "Down"
    }
    New-Object -TypeName PSObject -Property $status -OutVariable serverStatus
    $collection += $serverStatus
    
}
#$collection | Export-Csv C:\temp\ServerStatus.csv -NoTypeInformation
$collection | Export-Csv C:\temp\ServerStatus-$(Get-Date -format dd-MM-yyyy_hh-mm).csv -NoTypeInformation

วันจันทร์ที่ 9 มกราคม พ.ศ. 2560

Xenserver Change Pool Master

Changing the pool master on Xenserver is a simple task but it can be a little scary for the uninitiated. Typically this procedure is only needed during hardware failure or maintenance. If you are ready to proceed, lets get started!

Are you Using High Availability?

Before proceeding, you need to see if HA is enabled for the pool. The following command will list all pools along with UUID, name-label, and HA status.
If the pool you are working with returns “ha-enabled: true”, then it needs to be disabled with the following command.
Once high availability has been worked out, you can move on to the next step!

Who is the New Pool Master?

You will need the UUID of a different Xenserver host who will be the new po0l master. Grab the UUID of one of the hosts in the pool with the following command. More methods of grabbing Xenserver Host UUID can be found here.
Be careful not to select the old pool master!
Keep note of the UUID for the new host and move on.

Change Pool Master

Remember that UUID from the last step? Time to put it to use! Change the pool master with the following command.
If you found that you had HA enabled at the beginning of this article, it is time to re-enable it.

xe pool-ha-enable

วันพุธที่ 20 กรกฎาคม พ.ศ. 2559

Netlogon/sysvol not replicating

-Stop the File Replication Service on the failing DC ( net stop ntfrs )
-Set the "BurFlags" Value in the following registry key to "D2"(DWORD):
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\NtFrs\Parameters\Backup
/Restore\Process at Startup
-Start the File Replication Service. ( net start ntfrs )

วันพุธที่ 9 ธันวาคม พ.ศ. 2558

Renaming a Domino database with the server up


Renaming a Domino database with the server up

 If the server cannot be shut down, it is possible to rename the OS file name with the server up if there are no external third-party software factors to consider. Keep in mind that a server task acting on the database can create a database handle and not allow you to rename the file. To prevent this from occurring:

1. Let the user know you are going to rename their database and instruct them to exit their Lotus Notes® client. (Also, ensure that the database is not open by anyone else.)
2. Shut down the Domino Router by issuing tell router quit at the server console.
3. Issue the command drop database mail\filename.nsf
4. Make sure replication/cluster replication is not occurring.
5. Issue the command dbcache flush
6. Rename the database on the file system.
7. Update the Person document "Mail File" field to the new file name of the mail file.
8. Restart the Router task by issuing "load router" at the server console.
9. Make sure the end user's Location document is also updated with the new file name. (Location document -> Mail Tab -> "Mail file" field).

วันพุธที่ 21 มกราคม พ.ศ. 2558

วันอาทิตย์ที่ 16 กุมภาพันธ์ พ.ศ. 2557

"No Printers were found" Net work Printer Error

IF you can browse to the printer server where the printers are shared using an IP address only. i.e. \\10.100.1.x instead of \\printservername delete the following reg key and reboot the server.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Print\Providers


http://social.technet.microsoft.com/Forums/fr-FR/9af1dc6e-5213-45aa-8296-76ef21be6c19/no-printers-were-found-net-work-printer-error?forum=w7itpronetworking

วันศุกร์ที่ 14 กุมภาพันธ์ พ.ศ. 2557