regsvr32 schmmgmt.dll
FROM
tail -10 FILE
tail -n 10 FILE
cat FILE | tail -10
cat FILE | tail -n 10
Windows
Get-Content FILE | Select-Object -Last 10
gc FILE |select -Last 10
cat FILE | tail -f
Windows
Get-Content FILE -Wait
gc FILE -Wait
last reboot
uptimeWindows
systeminfo | find /i "Boot Time"
wmic os get lastbootuptime
Get-EventLog System | Where-Object {$_.EventID -eq "6005"}
@echo off
rem #1
set DD=%date%
set TT=%time%
echo %DD%-%TT%
rem #2
set datetimef=%date:~-4%-%date:~3,2%-%date:~0,2%_%time:~0,2%-%time:~3,2%-%time:~6,2%
echo %datetimef%
rem #3
set hour=%time:~0,2%
if "%hour:~0,1%" == " " set hour=0%hour:~1,1%
echo hour=%hour%
set min=%time:~3,2%
if "%min:~0,1%" == " " set min=0%min:~1,1%
echo min=%min%
set secs=%time:~6,2%
if "%secs:~0,1%" == " " set secs=0%secs:~1,1%
echo secs=%secs%
set year=%date:~-4%
echo year=%year%
set month=%date:~3,2%
if "%month:~0,1%" == " " set month=0%month:~1,1%
echo month=%month%
set day=%date:~0,2%
if "%day:~0,1%" == " " set day=0%day:~1,1%
echo day=%day%
set datetime1=%day%-%month%-%year%_%hour%-%min%-%secs%
echo datetime1=%datetime1%
netsh advfirewall firewall add rule name="zabbix" dir=in action=allow profile=domain description="zabbix agent 10050" enable=yes localport=10050 protocol=tcp
netsh advfirewall firewall del rule name="zabbix"
.
|_1
--|_2
----|_3
------|_4
--------|_test.txt
i="1/2/3/4" && mkdir -p $i && touch $i/test.txt
New-Item -Type file -Force 1\2\3\4\test.txt
mkfile() { mkdir -p "$1" && touch "$1"/"$2" }
mkfile 1/2/3/4 test.txt
Alt+D -> powershell -> Enter
ii .
or
start .
____________________ ii - Invoke-Item
start - Start-Process
"c:\Program Files (x86)\Skype\Phone\Skype.exe" /secondary
Get-ChildItem | Format-Wide -Property Name -column 1| Out-File File.lst
Позже обновлю
ldifde -f FILE.ldf -s SERVER.COM -d "ou=FIRST_OU,ou=SECOND_OU,dc=SERVER,dc=COM" -r "(objectCategory=CN=Person,CN=Schema,CN=Configuration,DC=SERVER,DC=COM)" -l "cn,title,department,description" -m -u -v -n
00 00 00 00 00 00 00 00 02 00 00 00 29 00 3A 00 00 00 00 00
выглядит :
Сохраняем. Закрываем редактор реестра.ntpdate ntp.domain
no server suitable for synchronization found
Запускаем редактор реестра:HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Config
Указываем значение параметра AnnounceFlags - Decimal 5net stop w32time
net start w32time
call MsgBox("Первая строка сообщения" & vbCrLf & "Вторая строка
чообщения" & vbCrLf & "Обратный отсчет числа:" & vbCrLf &
"30",0,"Заголовок окна")
Clear-Host
$curr_date = get-date -uFormat "%d"
$left_day = 30 - $curr_date
$new_left_day = $left_day - 1
$text = Get-Content Inform.vbs
$text -replace ("$left_day"), "$new_left_day" | Out-File Inform.vbs
Set-ExecutionPolicy RemoteSigned
chcp
chcp 866
chcp 1251
> $host.version
> Get-Host | Select-Object Version
[Shell]
Command=2
IconFile=Explorer.exe,3
[Taskbar]
Command=ToggleDesktop