Pages

Tuesday 24 July 2012

SCCM 2007 Corporate Training

AppREPACK houses an excellent team of  Technical Trainers, Development professionals. They form an integral part of the technical support system.Our practical approach lets you learn quickly through step-by-step procedures, using real-world scenarios. We offer both Classroom and Online training.


AppREPACK offers Corporate trainings on following platforms:
Application Repackaging/Packaging
Wise Package Studio
Installshield Adminstudio
SCCM 2007
Microsoft App-V


For more details, Please email Contact@Apprepack.in or visit www.apprepack.in

Sunday 22 July 2012

PowerShell PSDrive

To get the list of PowerShell Drives, Type the following command:



PowerShell Execution Policy Commands



Set-ExecutionPolicy Restricted

Set-ExecutionPolicy AllSigned

Set-ExecutionPolicy Unrestricted

Set-ExecutionPolicy RemoteSigned

When any of the above command is run, following registry value changes:


HKLM\Software\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell

Restricted
AllSigned
RemoteSigned
Unrestricted

PowerShell Execution Policy

Following are the execution policies available in PowerShell


1. Restricted: PowerShell Execution policy is set to Restricted by default which means powershell scripts are not allowed for execution


2. All Signed: In this policy, only the signed powershell scripts are allowed for execution


3. RemoteSigned: In this policy, all powershell unsigned scripts present on local harddrive are allowed for execution but scripts are executed remotely from a network share or from internet are not allowed for executed, 


   remote scripts need to be signed for execution.


4. UnRestricted: In this policy all powershell scripts whether they are signed or unsigned are allowed for execution.



Friday 20 July 2012

Start Service on Remote Computer - PowerShell


Following script will start the service "Browser"


$sb={
$service=get-service browser
if ($Service.status -eq "Stopped") {
write-Host "Starting service on $env:Computername" -foreground Green
$service | Start-service -PassThru
}
else {
$service
}
}

To run the above script type following command:

invoke-command $sb -comp remotecomputername

Result will be as follows: 


Connect to Remote Machine using Powershell



To connect to remote machine using PowerShell. WinRM (Windows Remote Management) service needs to be in started mode on the remote computer.


Then, run the following command on remote computer: WinRM quickconfig


Follow the steps displayed in command prompt to receive requests and remote management. Now the remote machine is ready to be accessed using powershell from any other computer.


Type following command in Powershell to access the remote machine:
-> Enter-PSSession ComputerName

Get Status of Service on a Remote Machine - PowerShell Command


Get-Service ServiceName -computername remotecompname | Select-object -Property Name,Status, MachineName