June 2014
M T W T F S S
 1
2345678
9101112131415
16171819202122
23242526272829
30  

Categories

June 2014
M T W T F S S
 1
2345678
9101112131415
16171819202122
23242526272829
30  

Centos 7 kickstart.cfg for cobbler

lang en_GB.UTF-8 keyboard us timezone Europe/Brussels –isUtc auth –useshadow –enablemd5 selinux –enforcing firewall –enabled –service=mdns xconfig –startxonboot part / –size 8192 –fstype ext4 services –enabled=NetworkManager –disabled=network,sshd # Root password rootpw –iscrypted $6$K2nKf02kVKG68960$OywvoaViphSITuro/liKvCj7Pm/CH/xqzz/lsoXyaKSR1lYf0vHAqSUc483a9MCCBkIwfr/hNMfqwxqVO0OEg1 repo –name=base –baseurl=http://ftp.redhat.com/redhat/rhel/rc/7/Client/x86_64/os/ %packages @base @core @fonts @gnome-desktop @input-methods @x11 #Live install tools anaconda system-config-keyboard grub2 firefox #Packages to remove for space […]

mount.nfs: rpc.statd is not running but is required for remote locking

I think i found the answer; even though chkconfig reported that “rpcbind” was setup to start in run level 3, for some reason it was not running. After this was started; I was able to mount the NFS share. # who -r run-level 3 2012-02-16 19:19 # chkconfig –list rpcbind rpcbind 0:off 1:off 2:on 3:on […]

Reasons ReFS

Resilient File System (ReFS) is a new file system introduced in Windows Server 2012. Initially, it is being targeted for implementation as a file system that is primarily used for file servers. However, starting as the file system for a file server is just the beginning. Like its predecessor, NTFS, ReFS will begin as a […]

PowerShell To Add IP Address

Setting an IP address PS C:\Users\Administrator> Get-NetAdapter

Name InterfaceDescription ifIndex Status MacAddress LinkSpeed —- ——————– ——- —— ———- ——— Ethernet0 Intel(R) 82574L Gigabit Network Conn… 12 Up 00-0C-29-3C-C0-2F 1 Gbps PS C:\Users\Administrator> Get-NetIPAddress -InterfaceIndex 12 -AddressFamily IPv4

 

To add the IP address use:

New-NetIPAddress -InterfaceIndex 12 -AddressFamily IPv4 -IPAddress 192.168.1.9 -PrefixLength 24

PowerShell to Shutdown Windows Server 2012

Launch PowerShell, type stop then tab, you should see Stop-Computer. If this flashy technique does not work, then just type this one simple command long-hand:

# PowerShell command to shutdown Windows Server 2012

Stop-Computer

 

shutdown utility. However, there is a little known switch to bring-up a GUI version of this command line utility.

# […]

Reboot Windows Server 2012 using Powershell

For occasions where you employ the shutdown command, then instead of typing -s, substitute -r.

# How to Reboot Server 2012 with PowerShell Restart-Computer

# How to Reboot with the built-in command Shutdown -r -m \\localhost

shutdown /r /t 0

 

Install and Remove DHCP SERVER Using PowerShell

Install DHCP SERVER Using PowerShell

 

PS C:\Users\Administrator> get-command -Module servermanager

CommandType Name ModuleName ———– —- ———- Alias Add-WindowsFeature ServerManager Alias Remove-WindowsFeature ServerManager Function Disable-ServerManagerStandardUserRemoting ServerManager Function Enable-ServerManagerStandardUserRemoting ServerManager Cmdlet Get-WindowsFeature ServerManager Cmdlet Install-WindowsFeature ServerManager Cmdlet Uninstall-WindowsFeature ServerManager

 

 

PS C:\Users\Administrator> Add-WindowsFeature -IncludeAllSubFeature -Name DHCP, RSAT-DHCP

Success Restart Needed Exit Code Feature Result ——- […]

Add A DHCP using PowerShell

Here is a quick powershell script to set your network card TCP/IP setting to dynamic addressing:

$NICs = Get-WMIObject Win32_NetworkAdapterConfiguration | where{$_.IPEnabled -eq “TRUE”}

Foreach($NIC in $NICs)

{

$NIC.EnableDHCP()

$NIC.SetDNSServerSearchOrder()

}

IPConfig /all

Add A Static IP using PowerShell

$NICs = Get-WMIObject Win32_NetworkAdapterConfiguration -computername . | where{$_.IPEnabled -eq $true -and $_.DHCPEnabled -eq $true} Foreach($NIC in $NICs) { $ip = “192.168.1.10” $gateway = “192.168.1.254” $subnet = “255.255.255.0” $dns = “8.8.8.8”,”192.168.1.254″ $NIC.EnableStatic($ip, $subnet) $NIC.SetGateways($gateway) $NIC.SetDNSServerSearchOrder($dns) $NIC.SetDynamicDNSRegistration(“FALSE”) } IPConfig /all

Diskpart to Create and Format Partitions

To use the command line to bring a disk online, create a partition, and format it, run the following commands:

June 20th, 2014 | Category: 2012 SERVER | Leave a comment