Categories
Archive
![]() Blogroll
|
Posted in Windows Powershell, Windows Server | No Comment | 143 views | 30/01/2012 01:36
Check-PSSnapin allows you to check specific PowerShell Snapin on server.
You can check PS Snapin like this: Check-PSSnapin -Name "Microsoft.SystemCenter.VirtualMachineManager" Name is mandatory, so you must give a name for that.
Posted in Windows Powershell, Windows Server | No Comment | 146 views | 30/01/2012 01:19
Check-WmiObject allows you to check Wmi provider/interface on given server.
You can check Wmi Provider like this: Check-WmiObject -NameSpace "root\virtualization" If you want to query different wmi host: Check-WmiObject -NameSpace "root\virtualization" -WmiHost "Server01" NameSpace is mandatory but you don’t need to type WmiHost if you query localhost.
Posted in Windows Powershell | No Comment | 232 views | 16/01/2012 23:43
I wrote a calendar sync script for Outlook to sync calendars between Exchange accounts. If you need to sync your calendars, accounts should be in same Outlook profile. I didn’t figure out how to sync between different profiles yet, but will work on it.
Every time you execute the script, it checks the duplicate entries. So you can’t sync if same appointment is also exist on other calendar. Also I thought to sync only new appointments, so there is a date checker too. You can change it if you want to sync all time appointments.
Posted in Virtual Machine Manager, Windows Powershell | 1 Comment | 228 views | 20/12/2011 21:41
If you have a public Hyper-V Cloud and use SCVMM, your customers can install Linux VM and install Hyper-V LIS v3.1 on it, there is nothing you can do to stop them. If they install it, you will not be able to use SCVMM due to LIS v3.1 bug. System.ArgumentException: Version string portion was too short or too long.
at System.Version..ctor(String version) at Microsoft.Carmine.ViridianImplementation.VirVMIntegrationService.PopulateKVPElements() There are 2 options to prevent this. If you have 0 – 50 VMs, it’s easy to deal with. But if you are a large Cloud provider, you can’t do it manually, you need scripting. So if you execute this command on SCVMM Powershell Interface, it’ll disable Data Exchange offer on all Linux VMs and save your SCVMM. Get-VM * | where {$_.OperatingSystem -notlike "*Windows*"} | Set-VM -EnableDataExchange $false As you see, it just looks for non-Windows machines and disable their Data Exchange offer. Good luck!
Posted in Windows Powershell | No Comment | 364 views | 30/11/2011 23:33
I’m happy to announce you my last product called PoSH Server. It’s an IIS alternative. Functionalities: Download: Donate: Usage: 1. First, you should allow signed Powershell scripts: Set-ExecutionPolicy AllSigned2. Extract file to any directory you want. 3. Import start.ps1 file: . .\start.ps1 4. Start PoSH Server: Start-PoSHServer5. Follow to instructions. Sample Web Site Preview: Sample Log Output Preview: It’s almost stable. I’ve added PHP 5.3.8 support but removed it due to unstable PHP performance. You can add PHP support if you need, that’s possible. It’s good to publish internal websites, should not be used for world wide website publishing. In large number of visitors, performance may be dramatically reduced.
Posted in Windows Powershell | No Comment | 437 views | 30/11/2011 20:57
You can’t run unsigned Powershell scripts on servers if execution policy is not set as “Unrestricted”. You need to sign your scripts to run without modifying security policies. If you are a software developer, signing your scripts makes you reliable publisher for users. By providing assurance that software is produced and signed by a “known publisher”, the practice of code signing can increase customer trust and lead to increased conversions and downloads.
But wait, you can’t sign a Powershell script with a Web certificate. So basically 20$ certificate from AlphaSSL or similar won’t work. For Windows, you need to have Code Signing Certificate. I’ll talk about GlobalSign code signing certificate and code signing process. If you are a individual developer (like me) you can go with that option. If you purchase individual developer certificate, you’ll get a certificate for your name (like Yusuf Ozturk). Let’s read it from GlobalSign:
Software Vendors and Organizations can digitally sign and timestamp the software they distribute over the Internet, ensuring that the end user knows the software is legitimate and has not been tampered with since being published.
Individual Developers, i.e. those developers not associated with larger organizations, can also buy and use Code Signing certificates. The full name of the developer is attached to the certificate, so customers will see the message “This software has been published by John Doe”. So what you need to get a code signing certificate?
Posted in Virtual Machine Manager, Windows Powershell | No Comment | 186 views | 29/11/2011 22:54
You may get this error when you try to start maintenance mode on a Hyper-V host. Error (10434)
No suitable host is available for migrating the existing highly available virtual machines. Recommended Action SCVMM can not live migrate virtual machines if a shared ISO file is attached. So that can pause maintenance mode if you choose live migration mode. Get-VM | Get-VirtualDVDDrive | where {$_.ISO -ne $null} | ft Name If you’re looking for a specific Hyper-V host called Host01: Get-VMHost Host01 | Get-VM | Get-VirtualDVDDrive | where {$_.ISO -ne $null} | ft Name Deattach shared ISO files from VMs and start maintenance mode again. |