Windows Power Shell Transcript P3

  • April 2020
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Windows Power Shell Transcript P3 as PDF for free.

More details

  • Words: 392
  • Pages: 3
********************** Windows PowerShell Transcript Start Start time: 20090421042843 Username : WOODGROVE\DusHar1 Machine : DC01 (Microsoft Windows NT 5.2.3790 Service Pack 1) ********************** Transcript started, output file is C:\FileManagementP3.txt PS C:\Documents and Settings\DusHar1> New-Item –path “c:\temp\” –itemtype “Directory” Directory: Microsoft.PowerShell.Core\FileSystem::C:\ Mode ---d----

LastWriteTime Length Name ------------- ------ ---4/21/2009 4:28 AM temp

PS C:\Documents and Settings\DusHar1> get-WmiObject -class Win32_Share | sort type, name Name ---Address CertConfig CertEnroll Certificate DC01.LOG NETLOGON Resources$ SYSVOL ADMIN$ C$ IPC$

Path Description -------------C:\Program Files\Exchsrvr\address "Access to address objects" C:\Shares\Certificate Certificate Services configuration C:\WINDOWS\system32\CertSrv\CertEnroll Certificate Services share C:\Shares\Certificate C:\Program Files\Exchsrvr\DC01.log Exchange message tracking logs C:\WINDOWS\SYSVOL\sysvol\woodgrove.c... Logon server share C:\Program Files\Exchsrvr\res "Event logging files" C:\WINDOWS\SYSVOL\sysvol Logon server share C:\WINDOWS Remote Admin C:\ Default share Remote IPC

PS C:\Documents and Settings\DusHar1> $objWMI = [wmiClass] 'Win32_share' PS C:\Documents and Settings\DusHar1> $objWMI |gm -memberType method |format-List TypeName : System.Management.ManagementClass#ROOT\cimv2\Win32_Share Name : Create MemberType : Method Definition : System.Management.ManagementBaseObject Create(System.String Path, System.String Name, System.UInt32 Type, System.UInt32 MaximumAllowed, System.String Description, System.String Password, System.Management.Managem entObject#Win32_SecurityDescriptor Access)

PS C:\Documents and Settings\DusHar1> $FolderPath = "C:\Temp" PS C:\Documents and Settings\DusHar1> $ShareName = " Temporary " PS C:\Documents and Settings\DusHar1> $Type = 0 PS C:\Documents and Settings\DusHar1> $objWMI = [wmiClass] 'Win32_share' PS C:\Documents and Settings\DusHar1> $objWMI.create($FolderPath, $ShareName, $Type)

__GENUS :2 __CLASS : __PARAMETERS __SUPERCLASS : __DYNASTY : __PARAMETERS __RELPATH : __PROPERTY_COUNT : 1 __DERIVATION : {} __SERVER : __NAMESPACE : __PATH : ReturnValue :0

PS C:\Documents and Settings\DusHar1> get-WmiObject -class Win32_Share | sort type, name Name ---Temporary Address CertConfig CertEnroll Certificate DC01.LOG NETLOGON Resources$ SYSVOL ADMIN$ C$ IPC$

Path Description -------------C:\Temp C:\Program Files\Exchsrvr\address "Access to address objects" C:\Shares\Certificate Certificate Services configuration C:\WINDOWS\system32\CertSrv\CertEnroll Certificate Services share C:\Shares\Certificate C:\Program Files\Exchsrvr\DC01.log Exchange message tracking logs C:\WINDOWS\SYSVOL\sysvol\woodgrove.c... Logon server share C:\Program Files\Exchsrvr\res "Event logging files" C:\WINDOWS\SYSVOL\sysvol Logon server share C:\WINDOWS Remote Admin C:\ Default share Remote IPC

PS C:\Documents and Settings\DusHar1> $ShareDel = get-WmiObject Win32_Share -filter "Name ='$ShareName' " PS C:\Documents and Settings\DusHar1> $ShareDel.delete() PS C:\Documents and Settings\DusHar1> get-WmiObject -class Win32_Share | sort type, name Name ---Address CertConfig CertEnroll Certificate DC01.LOG NETLOGON Resources$ SYSVOL ADMIN$ C$ IPC$

Path Description -------------C:\Program Files\Exchsrvr\address "Access to address objects" C:\Shares\Certificate Certificate Services configuration C:\WINDOWS\system32\CertSrv\CertEnroll Certificate Services share C:\Shares\Certificate C:\Program Files\Exchsrvr\DC01.log Exchange message tracking logs C:\WINDOWS\SYSVOL\sysvol\woodgrove.c... Logon server share C:\Program Files\Exchsrvr\res "Event logging files" C:\WINDOWS\SYSVOL\sysvol Logon server share C:\WINDOWS Remote Admin C:\ Default share Remote IPC

PS C:\Documents and Settings\DusHar1> Stop-transcript ********************** Windows PowerShell Transcript End

End time: 20090421043135 **********************

Related Documents