header image

Archive for January, 2019

To install or not

Posted by: | January 31, 2019 Comments Off on To install or not |

My recent posts about the NTFSsecurity module drew a comment that the cmdlets in the module couldn’t be used because they’re not installed on every server. This raises the question – to install or not. Windows systems have a huge array of PowerShell cmdlets available: – those from the PowerShell team that form the “core” […]

under: PowerShell

Start-Sleep change

Posted by: | January 31, 2019 Comments Off on Start-Sleep change |

Start-Sleep change in PowerShell v6.2 preview 4 Start-Sleep has had this syntax Start-Sleep [-Seconds] <int> [<CommonParameters>] Start-Sleep -Milliseconds <int> [<CommonParameters>]   since it was first introduced in PowerShell v1 (I think). You can define the period as a number of seconds or use the –Milliseconds option if you need a fraction of a second.   […]

under: PowerShell v6

Get-NTFSAcess

Posted by: | January 31, 2019 Comments Off on Get-NTFSAcess |

Get-NTFSAcess and Get-NTFSEffectiveAccess are two cmdlets from the NTFSsecurity module.   Get-NTFSAcess retrieves the access rights on a folder or file. You can immediately who has what rights and from where the rights are inherited.   Get-NTFSEffectiveAccess by contrast shows the rights YOU (the account you’re using to access the data) have to a file […]

under: PowerShell

Get-DiskSpace

Posted by: | January 30, 2019 Comments Off on Get-DiskSpace |

The Get-DiskSpace cmdlet from the NTFSsecurity module is useful in that it gives ready calculated percentages of free and used space: AvailableFreeSpacePercent : 56.73% AvailableFreeSpaceUnitSize : 270.11 GB ClusterSize : 4096 DriveName : \\?\Volume{c1c4c5bb-0000-0000-0000-f01500000000}\ TotalSizeUnitSize : 476.1 GB UsedSpacePercent : 43.27% UsedSpaceUnitSize : 206 GB FreeBytesAvailable : 290024239104 TotalNumberOfBytes : 511210610688 TotalNumberOfFreeBytes : 290024239104 BytesPerSector […]

under: PowerShell

PowerShell Admin Modules

Posted by: | January 29, 2019 Comments Off on PowerShell Admin Modules |

My PowerShell Admin Modules that used to be available through codeplex are now available on github – https://github.com/RichardSiddaway/PowerShell-Admin-Modules   I haven’t updated them since their original publication but they’re still valid   Enjoy

under: PowerShell

Long file paths

Posted by: | January 29, 2019 Comments Off on Long file paths |

Long file paths – greater than 260 characters – have been a pain to deal with in Windows.   There is an argument that you should avoid file paths of that length but sometimes you don’t have any choice – when you inherit a file structure for instance.   The following cmdlets from the NTFSsecurity […]

under: File System, PowerShell v5

PowerShell v6.2.0 preview 4

Posted by: | January 29, 2019 Comments Off on PowerShell v6.2.0 preview 4 |

PowerShell v6.2.0 preview 4 is now available from https://github.com/PowerShell/PowerShell/releases   After installation over the top of preview 3 I found that the PowerShell console would open and then immediately close when I tried to use it.  This is a known issue with a fix in the pipeline as far as I’m aware.  The workaround is to […]

under: PowerShell v6

NTFSsecurity module

Posted by: | January 25, 2019 Comments Off on NTFSsecurity module |

Just came across the NTFSsecurity module. Its available on the PowerShell gallery or from https://github.com/raandree/NTFSSecurity. The *-Acl cmdlets have been around since Windows PowerShell v1 but aren’t easy to use and don’t cover all our needs.   This module contains a number of cmdlets: Add-NTFSAccess Add-NTFSAudit Clear-NTFSAccess Clear-NTFSAudit Copy-Item2 Disable-NTFSAccessInheritance Disable-NTFSAuditInheritance Disable-Privileges Enable-NTFSAccessInheritance Enable-NTFSAuditInheritance Enable-Privileges […]

under: PowerShell v5, Security

PowerShell v6.1.2

Posted by: | January 21, 2019 Comments Off on PowerShell v6.1.2 |

PowerShell v6.1.2 was recently released – https://github.com/PowerShell/PowerShell/releases   There doesn’t seem to be any new functionality or breaking changes. Most of the changes seem to be internal to the project.   The issue with PowerShell not starting after installation over the top of an existing version seems to have been resolved.   The issue with […]

under: PowerShell v6

Windows sandbox

Posted by: | January 5, 2019 Comments Off on Windows sandbox |

The recent Windows 10 Insider builds (18305) have introduced a Windows sandbox feature. This is a new light weight desktop environment for testing software. A new sandbox is created every time you need one and EVERYTHING in the sandbox is destroyed when you close it. see https://blogs.windows.com/windowsexperience/2018/12/19/announcing-windows-10-insider-preview-build-18305/#ua844cXgClodRKz2.97 for the initial announcement. The IE fix KB4483214 seems […]

under: Windows 10

Older Posts »

Categories