How to Rename MAC HOSTNAME

How to Rename MAC HOSTNAME   scutil –get HostName scutil –get LocalHostName scutil –get ComputerName   To change the Host Name sudo scutil –set HostName HOSTNAME To change the Local Host Name sudo scutil –set LocalHostName HOSTNAME To change the Computer Name sudo scutil –set ComputerName HOSTNAME   dscacheutil -configuration

Youtube Download script

  Youtube Download script   Use Chrome Install Tampermonkey – https://chrome.google.com/webstore/detail/dhdgffkkebhmkfjojejmpbldmpobfkfo Install this script – https://greasyfork.org/en/scripts/1317-download-youtube-videos-as-mp4

Print spelling errors Linux TR script

Print spelling errors Linux TR script [sourcecode language=”bash”] tr ‘A-Z’ ‘a-z’ < doc.txt | tr -cs ‘a-z’ ‘\n’ | sort | uniq | comm -23 -/usr/share/dict/words [/sourcecode]

Profile Clean up

%AppData% %TMP% %TEMP% %LOCALAPPDATA% C:\Windows\Prefetch\*.* C:\Windows\Temp\*.* DiskCleanup Wizard Software Update Clean up Powerhsell

SCRIPTS: How to use RunDll32.exe

RunDll32.exe is a interesting tool that can be used in scripting.. rundll32.exe inetcpl.cpl ResetIEtoDefaults http://source.winehq.org/WineAPI/inetcpl.html RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 1DeleteCookies = 2, DeleteHistoryFiles = 8, DeleteFormData = 16, DeletePasswords = 32, DeleteHistory = 193, DeleteALLHistory = 255, DeleteTrackingInfo = 2048, PreserveFavourites = 8192, DeleteDownloadHistory = 16384, DeleteEverything = 22783 Delete History = 1 Delete Cookies = 2 Delete… Continue reading SCRIPTS: How to use RunDll32.exe

SCRIPT: VBScript Reboot Code

SCRIPT: VBScript Reboot Code [source] Set OpSysSet = GetObject("winmgmts:{authenticationlevel=Pkt," _ & "(Shutdown)}").ExecQuery("select * from Win32_OperatingSystem where "_ & "Primary=true") for each OpSys in OpSysSet retVal = OpSys.Reboot() next [/source]

Uptime Scanner

Uptime Scanner [source language=”vb”]</pre> Const ForReading = 1, ForWriting = 2, ForAppending = 3 Const CONVERT_TO_LOCAL_TIME = True Set FileSystemObject = CreateObject("Scripting.FileSystemObject") CurrentDirectory = left(WScript.ScriptFullName,(Len(WScript.ScriptFullName))-(len(WScript.ScriptName))) Set DeviceListFile = FileSystemObject.OpenTextFile(CurrentDirectory & "\serverlistall.txt", ForReading) Do Until DeviceListFile.AtEndOfStream Devicename = DeviceListFile.ReadLine If Trim(Devicename) <> "" Then Set dtmStartDate = CreateObject("WbemScripting.SWbemDateTime") dtmStartDate.SetVarDate dateadd("n", -10, now)’ CONVERT_TO_LOCAL_TIME Set winmgmts =… Continue reading Uptime Scanner

Simple Service Check

Simple Service Check   [source language=”vb”] @echo off <span style="line-height: 1.5em;">:start</span> for /f %%I in (serverlistall.txt) do call :run %%I goto :end :run echo %1 wmic /node:%1 service where StartMode="Auto" list brief > %1_before.txt goto :eof [/source]   [source language=”vb”] fc %1_before.txt %1_after.txt /U /LB | findstr "Stopped" > %1_compare.txt [/source]