viernes, 23 de febrero de 2018

LINUX. HowTo attribute execute file

To assign the execution attribute to a file:

Command: chmod +x




Sometimes is necessary change the owner of the file to can execute it, for this task:

Command: chown user:group



by GoN | Published: February 23, 2018 | Last Updated:

miércoles, 21 de febrero de 2018

jueves, 15 de febrero de 2018

WNDOWS. PS. Check Services

To do a html report of services status, you could do:


get-service | ConvertTo-Html -Property Name,Status | foreach { 
if ($_ -like "*<td>Running</td>*") {$_ -replace "<tr>", "<tr bgcolor=green>"} 
else {$_ -replace "<tr>", "<tr bgcolor=red>"}} > c:get-service.html
The result:

For a normal consult:

If you want start one service down automaticaly


Get-Service BITS | %{ if ( $_.Status -eq "Stopped" ) {Start-Service BITS}}





by GoN | Published: February 15, 2018 | Last Updated: April 10, 2018