Fast Easy way to Create USB Boot’able

Fast Easy way to Create USB Boot’able

OSX

[code=”bash”]

// BACKUP

diskutil unmount

Disk /dev/disk2 sudo dd if=/dev/disk2 of=foo.bar.img.dd bs=64k

// RESTORE

diskutil list

diskutil unmountDisk /dev/disk2

sudo dd if=foo.bar.img.dd of=/dev/disk2

Restores compressed image and write /dev/disk2 ###

sudo sh -c ‘gunzip -c backup.disk.img.dd.gz | dd of=/dev/disk2’

[/code]

[code]

lsblk

sudo umount /dev/sdx1

sudo dd bs=4M if=/path/to/ubuntu-18.04.2-desktop-amd64.iso of=/dev/sdx status=progress oflag=sync

[/code]

Windows Environment Commands

Windows Environment Commands

  • Change Proxy via Command

[source]

 

netsh winhttp set proxy proxy-server="proxy.:8080"
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings]
"ProxyServer"="proxy.:8080"
"AutoConfigURL"=""

reg import filename.reg

[/source]

  • KMS Activation

KMS Keys – http://technet.microsoft.com/en-us/library/jj612867.aspx

[source]

 

cscript //B "%windir%\system32\slmgr.vbs" -ckms
cscript //B "%windir%\system32\slmgr.vbs" -skms [kms_server_name]:1688
Find KMS Server – nslookup -type=srv _vlmcs._tcp
cscript //B "%windir%\system32\slmgr.vbs" -skms –ipk <kms key>
cscript //B "%windir%\system32\slmgr.vbs" -skms –ato

[/source]

  • Find User Account with ForeignSecurityPrincipal / SAMID

[source]

$pw = read-host "Enter password" -AsSecureString
connect-QADService -service ‘*.com.au’ -ConnectionAccount ‘domain\username’ -ConnectionPassword $pw
(get-QADObject -identity ‘S-1-5….’).DirectoryEntry.description
disconnect-QADService

[/source]

  • Show SAMID of user account

[source]

dsquery * -filter "&(objectcategory=user)(samaccountname=accountname)" -attr objectsid
dsquery * -filter "&(objectcategory=user)(samaccountname=*)" -attr objectsid -limit 100000000
dsget user "cn=username,OU=,DC=corpau,DC=com,DC=au" -sid

[/source]

netsh int ipv4 show dynamicport tcp
netsh int ipv4 show dynamicport udp
netsh int ipv4 set dynamicport tcp start=10000 num=1000
netsh int ipv4 set dynamicport udp start=10000 num=1000

  • Find domain controllers

[source]netdom query dc[/source]

  • Windows Update

[source]

net stop wuauserv
%windir%\Windowsupdate.log
HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate

wmic qfe list full /format:htable | findstr "KB2621440"

wmic qfe list full | findstr "KB2621440"

[/source]

  • KMS

[source]

cscript //B "%windir%\system32\slmgr.vbs" -ckms
cscript //B "%windir%\system32\slmgr.vbs" -skms
Find KMS Server – nslookup -type=srv _vlmcs._tcp

[/source]

  • Dsgets

[source]

dsquery ou domainroot

dsquery user -name Ja*

dsget uer CN=*,CN=*,DC=*,DC=*,DC=*,DC=com,DC=au -memberof -expand

dsquery user -name *| dsget user -memberof -expand

dsquery "DC=com,DC=au"  | dsget group -members

[/source]

  • Systeminfo

[source]

systeminfo /S A* /U /P  findstr  "Processor"

WMIC CPU Get NumberOfCores,NumberOfLogicalProcessors /Format:List

WMIC CPU Get /Format:List

[/source]

  • NSanity

[source]</pre>
c:\nsanity.exe -S snapmanager windows://ServerName
[/source]

  • nmap

[source]
nmap -vv -P0 -sU -p123
[/source]

  • Find Domain controllers

[source]

<strong>dsquery server</strong><strong> -hasfsmo</strong><strong> pdc</strong>

netdom query /d:domain pdc or dc

[/source]

Windows 7 Backup Image Restore

IMPORTANT: Windows 7 Image Restore only restore the partition that the C: drive system files are located on. You will need to backup all other partitions to another physical location or media.

Backup the Workstation

1. Type SDCLT.exe in the RUN box to bring up the Backup and Restore program

2. Create a Full backup of all Partitions and SYSTEM STATE to another media

3. Create a System Repair Image

4. Burn System Image Backup to a DVD

5. Boot with System Restore CD

6. Select Restore from Image and Insert you Image Backup DVD

7. Boot to Windows and Restore all other volume..

Reference Links :

http://www.petri.co.il/restore-windows-7-from-backup-image.htm

http://www.petri.co.il/working-with-system-image-backups-in-windows-7.htm