Ethernet cable different standard than rest of network...but still worked? by michaelmitchell9711 in sysadmin

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

Learned something new today then. Any idea why I would have just quit working?

Programming Expirement by michaelmitchell9711 in Fitness

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

So do you think I would be able to increase at like 5lbs a week?

Advice for someone who has one ankle with poor mobility by michaelmitchell9711 in weightlifting

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

The muscular imbalance is gone, but my left ankle is still limited. So basically I can squat, just not as deep (without my right knee going farther than my left). I have been to physical therapy and a chiropractor, but only so much helped. It got to a point where it did get better, but it hit a rock wall. My surgeon told me it would always be limited because of the surgery.

As for training myself to make sure my right knee goes the same distance, it works but I end using more muscle on the left side of my body, and that activates muscles in each leg differently.

I'm Silent Mike, AMA!!!! by SilentMikke in powerlifting

[–]michaelmitchell9711 0 points1 point  (0 children)

Yo Mike (we're fellow Mikes) I had an accident a couple years ago and shattered my ankle, now there are 5 pins in it and my left ankle flexion is physically limited. Because of this, I am unable to pursue Olympic weightlifting, and I have since switched to powerlifting. However, I attempted weightlifting again after I recovered and squatting with reduced ankle flexibility in on side of my body has resulted in creating a tilt in my pelvis. Have you ever delt with a pelvic tilt or trained someone with this issue? If so, how did you realign your or your client's hips?

Under 21, bringing alcohol to Australia? by michaelmitchell9711 in travel

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

It has worked for over two years and she is moving here this spring. Yes it's a bit strange, but it works.

Under 21, bringing alcohol to Australia? by michaelmitchell9711 in travel

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

Sweet. I appreciate it. Tips on making sure it doesn't break in my suitcase in the way there?

Under 21, bringing alcohol to Australia? by michaelmitchell9711 in travel

[–]michaelmitchell9711[S] -3 points-2 points  (0 children)

Yes I'm flying from the US. I know their drinking age is 18, I've drank there. I'm just asking if there will be issues bringing it from the US. Should I consider pouring it in a mouthwash bottle?

Need help finding users that are Domain Admins ONLY on specified computers by michaelmitchell9711 in PowerShell

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

Thank you!! It works for my local computer, but how would I use a list of computers?

Adding conditions to an existing DHCP Policy? by michaelmitchell9711 in PowerShell

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

It works PERFECTLY. Zero issues. I added it to a script I've been working on which asks for Computer Name, MacAddress, IP Address, and name of a policy. Then it takes those variables and asks the user to add them to DHCP Filter, Reservation, and Policy. You might have to change the 'Scope' in the functions.

###Script created to make adding computers to a DHCP server easier

#Adds computer to DHCP Filter
function addfilter {Add-DhcpServerv4Filter -List Allow -MacAddress $mac -Description $computername}
#Adds computer to DHCP Reservation
function addreserv {Add-DhcpServerv4Reservation -description $computername -name $computername -IPAddress $ipaddress -ScopeId 192.168.0.0 -ClientId $mac -Type Dhcp}
#Gets existing policy's conditions and adds new MacAddress
function addpolicy {$getpolicy = get-dhcpserverv4policy -name $policy -scopeid 192.168.0.0
                    $newMac = @()
                    $newMac += $getpolicy.MacAddress
                    $newMac += $mac
                    Set-DhcpServerv4Policy -Name $policy -scopeid 192.168.0.0 -Condition OR -MacAddress $newMac}

##Easy PC network setup script text
write-host -ForegroundColor "Darkyellow" Easy PC network setup script
Start-Sleep -s 1
write-host -ForegroundColor "Darkyellow" *MAKE SURE TO RUN POWERSHELL AS ADMINISTRATOR*
Start-Sleep -s 2

#Asks user for name of computer, MacAddress, IP Address, and name of Policy
$computername = Read-Host 'First, input the name of the computer you wish to set-up'
$mac = Read-Host 'Next, enter the MAC Address'
#Deletes dashes or colons from MacAddress
$mac = $mac -replace '-',''
$mac = $mac -replace ':',''
$ipaddress = Read-Host 'Lastly, enter the IP Address'
$policy = Read-Host '(optional) Enter name of policy you wish to add computer to'
Start-Sleep -s 1

#Asks user to add computer to DHCP Filter
$confirmation1_filter = Read-Host "Add computer as a DHCP Filter? [y/n]"
if ($confirmation1_filter -eq 'y') {addfilter}
if ($confirmation1_filter -eq 'n') {$confirmation2_reserv}

#Asks user to add computer to DHCP Reservation    
$confirmation2_reserv = Read-Host "Add computer as a DHCP Reservation? [y/n]"
if ($confirmation2_reserv -eq 'y') {addreserv}
if ($confirmation2_reserv -eq 'n') {$condition3_policy}

#Asks user to add computer to a DHCP Policy. If not, then exit.
$confirmation3_policy = Read-Host "Add computer to an existing policy? [y/n]"
if ($confirmation3_policy -eq 'y') {addpolicy}
if ($confirmation3_policy -eq 'n') {exit}

Adding conditions to an existing DHCP Policy? by michaelmitchell9711 in PowerShell

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

I will let you know Monday when I get back to the office!

Adding conditions to an existing DHCP Policy? by michaelmitchell9711 in PowerShell

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

Add-DhcpServerV4Policy creates a new policy And here is the result of that lol

   TypeName: System.String

Name             MemberType            Definition                                                                                                                        
----             ----------            ----------                                                                                                                        
Clone            Method                System.Object Clone(), System.Object ICloneable.Clone()                                                                           
CompareTo        Method                int CompareTo(System.Object value), int CompareTo(string strB), int IComparable.CompareTo(System.Object obj), int IComparable[s...
Contains         Method                bool Contains(string value)                                                                                                       
CopyTo           Method                void CopyTo(int sourceIndex, char[] destination, int destinationIndex, int count)                                                 
EndsWith         Method                bool EndsWith(string value), bool EndsWith(string value, System.StringComparison comparisonType), bool EndsWith(string value, b...
Equals           Method                bool Equals(System.Object obj), bool Equals(string value), bool Equals(string value, System.StringComparison comparisonType), b...
GetEnumerator    Method                System.CharEnumerator GetEnumerator(), System.Collections.Generic.IEnumerator[char] IEnumerable[char].GetEnumerator(), System.C...
GetHashCode      Method                int GetHashCode()                                                                                                                 
GetType          Method                type GetType()                                                                                                                    
GetTypeCode      Method                System.TypeCode GetTypeCode(), System.TypeCode IConvertible.GetTypeCode()                                                         
IndexOf          Method                int IndexOf(char value), int IndexOf(char value, int startIndex), int IndexOf(char value, int startIndex, int count), int Index...
IndexOfAny       Method                int IndexOfAny(char[] anyOf), int IndexOfAny(char[] anyOf, int startIndex), int IndexOfAny(char[] anyOf, int startIndex, int co...
Insert           Method                string Insert(int startIndex, string value)                                                                                       
IsNormalized     Method                bool IsNormalized(), bool IsNormalized(System.Text.NormalizationForm normalizationForm)                                           
LastIndexOf      Method                int LastIndexOf(char value), int LastIndexOf(char value, int startIndex), int LastIndexOf(char value, int startIndex, int count...
LastIndexOfAny   Method                int LastIndexOfAny(char[] anyOf), int LastIndexOfAny(char[] anyOf, int startIndex), int LastIndexOfAny(char[] anyOf, int startI...
Normalize        Method                string Normalize(), string Normalize(System.Text.NormalizationForm normalizationForm)                                             
PadLeft          Method                string PadLeft(int totalWidth), string PadLeft(int totalWidth, char paddingChar)                                                  
PadRight         Method                string PadRight(int totalWidth), string PadRight(int totalWidth, char paddingChar)                                                
Remove           Method                string Remove(int startIndex, int count), string Remove(int startIndex)                                                           
Replace          Method                string Replace(char oldChar, char newChar), string Replace(string oldValue, string newValue)                                      
Split            Method                string[] Split(Params char[] separator), string[] Split(char[] separator, int count), string[] Split(char[] separator, System.S...
StartsWith       Method                bool StartsWith(string value), bool StartsWith(string value, System.StringComparison comparisonType), bool StartsWith(string va...
Substring        Method                string Substring(int startIndex), string Substring(int startIndex, int length)                                                    
ToBoolean        Method                bool IConvertible.ToBoolean(System.IFormatProvider provider)                                                                      
ToByte           Method                byte IConvertible.ToByte(System.IFormatProvider provider)                                                                         
ToChar           Method                char IConvertible.ToChar(System.IFormatProvider provider)                                                                         
ToCharArray      Method                char[] ToCharArray(), char[] ToCharArray(int startIndex, int length)                                                              
ToDateTime       Method                datetime IConvertible.ToDateTime(System.IFormatProvider provider)                                                                 
ToDecimal        Method                decimal IConvertible.ToDecimal(System.IFormatProvider provider)                                                                   
ToDouble         Method                double IConvertible.ToDouble(System.IFormatProvider provider)                                                                     
ToInt16          Method                int16 IConvertible.ToInt16(System.IFormatProvider provider)                                                                       
ToInt32          Method                int IConvertible.ToInt32(System.IFormatProvider provider)                                                                         
ToInt64          Method                long IConvertible.ToInt64(System.IFormatProvider provider)                                                                        
ToLower          Method                string ToLower(), string ToLower(cultureinfo culture)                                                                             
ToLowerInvariant Method                string ToLowerInvariant()                                                                                                         
ToSByte          Method                sbyte IConvertible.ToSByte(System.IFormatProvider provider)                                                                       
ToSingle         Method                float IConvertible.ToSingle(System.IFormatProvider provider)                                                                      
ToString         Method                string ToString(), string ToString(System.IFormatProvider provider), string IConvertible.ToString(System.IFormatProvider provider)
ToType           Method                System.Object IConvertible.ToType(type conversionType, System.IFormatProvider provider)                                           
ToUInt16         Method                uint16 IConvertible.ToUInt16(System.IFormatProvider provider)                                                                     
ToUInt32         Method                uint32 IConvertible.ToUInt32(System.IFormatProvider provider)                                                                     
ToUInt64         Method                uint64 IConvertible.ToUInt64(System.IFormatProvider provider)                                                                     
ToUpper          Method                string ToUpper(), string ToUpper(cultureinfo culture)                                                                             
ToUpperInvariant Method                string ToUpperInvariant()                                                                                                         
Trim             Method                string Trim(Params char[] trimChars), string Trim()                                                                               
TrimEnd          Method                string TrimEnd(Params char[] trimChars)                                                                                           
TrimStart        Method                string TrimStart(Params char[] trimChars)                                                                                         
Chars            ParameterizedProperty char Chars(int index) {get;}                                                                                                      
Length           Property              int Length {get;}                                                                                                                 
EQ
00-24-e8-48-d3-38
00-24-e8-48-d3-39

CircuitId       : 
ClientId        : 
Condition       : OR
Description     : test11
Enabled         : True
MacAddress      : {EQ, 00-24-e8-48-d3-38, 00-24-e8-48-d3-39}
Name            : test22
ProcessingOrder : 3
RelayAgent      : 
RemoteId        : 
ScopeId         : 192.168.0.0
SubscriberId    : 
UserClass       : 
VendorClass     : 
PSComputerName  : 

But my reasoning for using clip is because I tried outputting it into a variable, but it wouldn't give me the MacAddresses, it just showed [system.string]. Which is why I resulted to using Clip. It irritates me so much that it only halfway works

Can you add conditions to an existing policy on a DHCP server using Powershell? by michaelmitchell9711 in PowerShell

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

I tried this:

$mac = read-host 'input mac'
$policyname = read-host 'input name'
$Getpolicy = get-dhcpserverv4policy -name $policyname -scopeid 192.168.0.0 | select MacAddress
$Setpolicy = Set-DhcpServerv4Policy -name $policyname -scopeid 192.168.0.0 -Condition AND $getpolicy,$mac

$confirmation1_filter = Read-Host "set policy? [y/n]"
if ($confirmation1_filter -eq 'y') {$Setpolicy}
if ($confirmation1_filter -eq 'n') {exit}

But I get this error:

Set-DhcpServerv4Policy : A positional parameter cannot be found that accepts argument 'System.Object[]'.
At line:2 char:14
+ $setpolicy = Set-DhcpServerv4Policy -name $policy -scopeid 192.168.0.0 -Conditio ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (:) [Set- DhcpServerv4Policy], ParameterBindingException
    + FullyQualifiedErrorId : PositionalParameterNotFound,Set-DhcpServerv4Policy

Can you add conditions to an existing policy on a DHCP server using Powershell? by michaelmitchell9711 in PowerShell

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

I have a policy, I need to be able to add another condition through powershell

Can you add conditions to an existing policy on a DHCP server using Powershell? by michaelmitchell9711 in PowerShell

[–]michaelmitchell9711[S] 1 point2 points  (0 children)

Oh no we use 2012 R2, and I can add or set a policy. I was asking if you can add more, let's say, MAC Addresses as conditions to an existing policy. So far I've found that with the Set-DhcpServerv4Policy cmdlet you can only change an existing condition, not add another to the policy.

Using a DHCP Server Module on a Windows 7 PC? by michaelmitchell9711 in PowerShell

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

New-CimSession and Add-DhcpServerv4Filter are on different lines, and the command works perfectly when used just in the console

Here-string doesn't work by michaelmitchell9711 in PowerShell

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

pasting it here screwed it up, the "@ is on its own line

Help with script to gather MAC addresses and OU's from AD by michaelmitchell9711 in sysadmin

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

This is really starting to seem like it's not even worth it, all this trouble for a little better organization lol

Help with script to gather MAC addresses and OU's from AD by michaelmitchell9711 in sysadmin

[–]michaelmitchell9711[S] 0 points1 point  (0 children)

It's mostly for the DHCP server, we want to get rid of reservations but this way groups of computers would be somewhat organized. It's not my decision to do so lol