Diskpart commands


diskpart

list disk

list volume

list vdisk

select volume 0

clean

convert gpt – Converts to GPT partition

create partition efi size=100

format quick fs=fat32 label=”system”

assign letter=”s”

create partition msr size=128

partition primary

format

format quick fs=ntfs label=”nanoserver”

assign letter=”n”

list volume

exit

 

Advertisements

PowerShell cmd – disk no & UUID


Get-Disk | Select number, uniqueid

This will list all the disks (including LUNs if any) and its corresponding Unique ID (UUID)

Open Disk manager (diskmgmt.msc) to identify the Lun, Disk number and use the PowerShell output to fetch the unique ID (UUID)

Fixed: The software change returned error code 0x80091007 (-2146889721) – SCCM (software center)


While I was trying to install an application through Software Center (SCCM) on a server. It was failing with the above error:

The software change returned error code 0x80091007 (-2146889721)

 

To resolve it, disable Anti-virus on the server and try to install the application again. It will succeed.

 

Solved: The trust relationship between this workstation and the primary domain failed.


If you get this error, the normal procedure is to change the server from Domain to workgroup -> Restart the server -> Then again change it back from Workgroup to Domain -> Restart the server.

But what if you need to fix the issue without restarting the server ?

Login to the problematic server with local admin login credentials -> Launch PowerShell with run as administrator

$Cred=Get-Credential

Here give your Domain login credential (make sure that has privileges to execute the below command)

Reset-ComputerMachinePassword -Credential $cred -Server DomainControllername

This will fix the issue


 

If the issue still persists, then follow the below steps:

  1. Join the server to workgroup and restart it
  2. Wait for few minutes
  3. Delete the object in the Active directory user and computers (dsa.msc)
  4. Join the server back to domain

Now you the issue should be resolved.

Robocopy


Copy paste from Technet.Microsoft.

Robocopy (the name is short for Robust File Copy) was introduced with the Windows Server 2003 Resource Kit and is included in all editions of Windows 7. Its many strengths include the ability to copy all NTFS file attributes and to mirror the contents of an entire folder hierarchy across local volumes or over a network. If you use the right combination of options, you can recover from interruptions such as network outages by resuming a copy operation from the point of failure after the connection is restored.

The Robocopy syntax takes some getting used to. If you’re familiar with the standard Copy and Xcopy commands, you’ll have to unlearn their syntax and get used to Robocopy’s unconventional ways. The key difference is that Robocopy is designed to work with two directories (folders) at a time, and the file specification is a secondary parameter. In addition, there are dozens of options that can be specified as command-line switches. The basic syntax is as follows:

robocopy source destination [file [file]…] [options]

The source and destination parameters are specified as drive:\path or \\server\share\path. The file parameter can contain one or more literal file names, or it can use the familiar ? and * wildcards. Available options include dozens of switches that control copying, file selection, retry options, and the ability to create log files. For instance, this command copies the contents of one folder and all its subfolders from a local drive E to a shared folder on a Windows Home Server:

robocopy “E:\test” \\server\public\test\ /MIR /W:20 /R:15 /LOG: \\server\public\logs

The /MIR switch tells Robocopy you want to mirror the two folders, copying all folders (even empty ones) from the source directory and purging folders from the destination if they no longer exist on the source. The /W and /R switches set the wait and retry options; in this case, Robocopy will retry each copy up to 15 times, waiting 20 seconds between attempts. (The defaults allow 1 million retries, at 30-second intervals, allowing copy operations to complete when an open file is closed, even if hours or days have passed since the command was first launched.)

To see the full syntax, type robocopy /? at a command prompt.

Robocopy is a powerful tool, capable of moving, copying, and deleting files and folders faster than you can say “Whoops.” We recommend experimenting with commands using nonessential files and folders first; when you’re comfortable that you understand the effects of the syntax you’re using, you can run the command against real data files.

And if you aren’t keen on the idea of using a command-line tool, take heart. Microsoft engineer Derk Benisch has written a graphical front end that allows you to build a command by selecting check boxes instead of entering switches.

Robocopy GUI adds more than usability to Robocopy; it also lets you create a library of commonly used copy scripts.

Robocopy GUI:

https://technet.microsoft.com/en-us/library/2006.11.utilityspotlight.aspx

Protocols used for Monitoring – WMI, SNMP, SSH, IPMI


While assigning systems into Monitoring we need to mention the protocol for the particular system we want to monitor. Power Admin Server Monitor requires you to mention this.

WMI – Windows servers uses WMI (Windows Management Instrumentation)

SNMP – Windows and Linux servers uses SNMP (Simple Network Management Protocols)

SSH – Linux and firewalls uses SSH protocol (Secure Shell)

IPMI – Dell DRAC, HP iLo, Dell RSA uses IPMI (Intelligent Platform Management Interface)

 

Screenshot from Power Admin Server Monitor