RE: Bad symbolic link in registry

2013-04-28 Thread Joseph L. Casale
Running regedt32 with elevated credentials? Ensured no running services are 
holding the key open?

Yeah, no luck...
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Bad symbolic link in registry

2013-04-28 Thread Joseph L. Casale
 How about a rename?

When I recreate the target so I can access it, if I rename the symlink, it 
accepts its, renames the
target, but reverts after a refresh leaving the target renamed?

I am remote and its a vm for which I dont have console access to, what a pita 
this turning
out to be.

jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Startup processes

2013-04-25 Thread Joseph L. Casale
If you can query for the process, can you not query the network?
Lookup the gateway and ping it...

From: kz2...@googlemail.com
Sent: Thursday, April 25, 2013 6:11 AM
To: NT System Admin Issues
Subject: Startup processes

On a Windows system, is there a process that runs on startup that will only run 
if there is network connectivity present? I've got a strange requirement and I 
need to be able to tell when the network is available, if possible.

TIA,


JR


Sent from my Blackberry, which may be an antique but delivers email RELIABLY

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: SCCM 2012 quick question

2013-04-17 Thread Joseph L. Casale
scclient.exe

From: James Rankin
Sent: Wednesday, April 17, 2013 6:30 AM
To: NT System Admin Issues
Subject: SCCM 2012 quick question

Anyone know what the executable name for Software Center in SCCM 2012 is? I've 
seen it suggested as scclient.exe and ccmsetup.exe, as I don't have a copy of 
this version could anyone quickly confirm the right name for me?

Thanks in advance,



--
James Rankin
Technical Consultant (ACA, CCA, MCTS)
http://appsensebigot.blogspot.co.ukhttp://appsensebigot.blogspot.co.uk/

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: PowerShell - Dependent parameters

2013-04-12 Thread Joseph L. Casale
but I can't figure out how to tell it one parameter *depends* on another.

Create your parameter set, then set the few that depend on each other to be
mandatory?

There are some neater things you can do with compiled code, otherwise you
sometimes have to do more exotic validation after the param block...

jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Running Powershell script as scheduled task fails with 0x1

2013-03-08 Thread Joseph L. Casale
Sorry to reply out of thread order (dont have the original).

No need to sigh, ditch the bad posts on the net and run `powershell /?`

A ps1 file is not a command. You need to invoke the script.

-Original Message-
From: Michael Leone [mailto:oozerd...@gmail.commailto:oozerd...@gmail.com]
Sent: Thursday, March 7, 2013 1:59 PM
To: NT System Admin Issues
Subject: Re: Running Powershell script as scheduled task fails with 0x1

On Thu, Mar 7, 2013 at 2:37 PM, Webster 
webs...@carlwebster.commailto:webs...@carlwebster.com wrote:
 I thought it was -File c:\scripts\myscript.ps1.

See, this is what's infuriating. Most of the examples I have found say you 
don't need -Command or -File. Some say -Command. Some say the 2 are 
equivalent.

SIGH

So I changed it to -File, and made sure the folder holding the script itself 
had no spaces in its name. And then it all started working ...

I thought for sure I had tried it with -File as well, but maybe not.

Anyways, it all seems good now. Thanks.



 Carl Webster
 Consultant and Citrix Technology Professional
 http://www.CarlWebster.com


 -Original Message-
 From: Michael Leone [mailto:oozerd...@gmail.commailto:oozerd...@gmail.com]
 Sent: Thursday, March 07, 2013 2:30 PM
 To: NT System Admin Issues
 Subject: Running Powershell script as scheduled task fails with 0x1

 I can't understand why my script is failing. I can run it from a Powershell 
 prompt (I have to Run as administrator, because the script is deleting some 
 files in a backup directory). But it works perfectly when I do it that way. 
 But when I create a Scheduled Task to do it, it fails with 0x1.

 I create a Task, tell it to use an account with domain admin
 privileges. Tell it to run whether the user is logged on or not, and
 to run with highest privileges The action calls a program
 (C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe). In Add
 arguments, I have

 -Command C:\Scripts\myscript.ps1




 ~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~
 http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

 ---
 To manage subscriptions click here:
 http://lyris.sunbelt-software.com/read/my_forums/
 or send an email to 
 listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
 with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Recommendations for DNS/SSL provider

2013-02-25 Thread Joseph L. Casale


 There is currently some discussion about moving away from them due to various
 concerns around them (not just technical issues).



Alright, you can't just leave us there:) What's the issue? I have a few 
companies setup
with them?


jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell question

2013-02-14 Thread Joseph L. Casale
Ugh, just got schooled by a .net dev:)

So the issue is that when I use an xpath to carve up an xml config file locally 
and ship the System.Xml.XmlDocument
object off to a remote computer via remoting, it gets serialized, so its almost 
useless at the far end.

What I plan to do is convert all the configs fanned out to the set hosts to a 
string object so it does not undergo serialization.

[XML]$XML = Get-Content 'C:\Data\config.xml'

$StringWriter = New-Object System.IO.StringWriter
$XmlWriter = New-Object System.XMl.XmlTextWriter $StringWriter
$xmlWriter.Formatting = indented
$xmlWriter.Indentation = '4'
$xml.WriteContentTo($XmlWriter)
$XmlWriter.Flush()
$StringWriter.Flush()
$StringWriter.ToString()

A bit much to go through, but it gets what I need. I'll pass this in as an arg 
to the invoke cmd and convert to an xml object
to get the nice parsing/xpath ability...

Thanks!
jlc


From: Michael B. Smith
Sent: Thursday, February 14, 2013 5:21 PM
To: NT System Admin Issues
Subject: RE: Powershell question

ToString() doesn't work for you? Convert-* don't work for you?

I'm a little confused as to what you want to do...

From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Thursday, February 14, 2013 7:14 PM
To: NT System Admin Issues
Subject: Powershell question

Hey guys,
I have a System.Xml.XmlDocument object I want to convert back to textual 
representation so I can save it in a variable.

The .Save() method allows for a console object, anyone know how to do this for 
a variable?

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Networking stuff.....oo-er

2013-01-26 Thread Joseph L. Casale
        yum update all 


That syntax hasn't been around in ages:) The 'all' keyword is no longer used.
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Installing Microsoft Update Standalone Packages Silently question

2013-01-01 Thread Joseph L. Casale
Does someone actually use wordpad for anything?

My guess, character set and wordpad bungles it up. Use notepad, or a real 
editor like vi :)


From: Webster
Sent: Tuesday, January 1, 2013 9:36 AM
To: NT System Admin Issues
Subject: Installing Microsoft Update Standalone Packages Silently question

Greetings oh wise ones,

On this project I am on, I need to install the MS recommended hotfixes from 
http://support.citrix.com/article/CTX129229 .

I have the following in my batch file:

wusa c:\install\xenapp\Windows6.1-KB917607-x64.msu /quiet /norestart 
/log:c:\install\xenapp\logs\MicrosoftHotfixKB917607Log.txt
wusa c:\install\xenapp\Windows6.1-KB2444328-v2-x64.msu /quiet /norestart 
/log:c:\install\xenapp\logs\MicrosoftHotfixKB2444328Log.txt
wusa c:\install\xenapp\Windows6.1-KB2465772-x64.msu /quiet /norestart 
/log:c:\install\xenapp\logs\MicrosoftHotfixKB2465772Log.txt
wusa c:\install\xenapp\Windows6.1-KB2551503-x64.msu /quiet /norestart 
/log:c:\install\xenapp\logs\MicrosoftHotfixKB2551503Log.txt
wusa c:\install\xenapp\Windows6.1-KB2571388-x64.msu /quiet /norestart 
/log:c:\install\xenapp\logs\MicrosoftHotfixKB2571388Log.txt
wusa c:\install\xenapp\Windows6.1-KB2578159-x64.msu /quiet /norestart 
/log:c:\install\xenapp\logs\MicrosoftHotfixKB2578159Log.txt
wusa c:\install\xenapp\Windows6.1-KB2617858-x64.msu /quiet /norestart 
/log:c:\install\xenapp\logs\MicrosoftHotfixKB2617858Log.txt

The updates get installed but the log files generated just contain gibberish.  
In addition, each log file also get a .dpx file.  Any idea why the log file 
is unreadable and what the dpx file is?

[cid:image001.png@01CDE80B.E62151C0]

Google isn't turning up anything on this.

BTW, Happy New Year.

Thanks


Webster


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmininline: image001.png

RE: Installing Microsoft Update Standalone Packages Silently question

2013-01-01 Thread Joseph L. Casale
Cool, here's an interesting tidbit:
http://social.technet.microsoft.com/wiki/contents/articles/how-to-install-multiple-windows-updates-and-or-hotfixes-in-a-time.aspx


From: Webster
Sent: Tuesday, January 1, 2013 2:00 PM
To: NT System Admin Issues
Subject: RE: Installing Microsoft Update Standalone Packages Silently question

I gave up on the log files and resorted to using PoSH.

$MyTime =(Get-Date).AddMinutes(-10)
$wusa = get-winevent -filterhashtable 
@{logname=setup;providername=Microsoft-Windows-WUSA;starttime=$MyTime}
$wusa | fl | out-file c:\install\xenapp\logs\MicrosoftHotfixes.txt

This grabs all the WUSA events in the Setup event log that happened within the 
last 10 minutes and sends them to a log file that makes the QA people happy.

Thanks


Webster

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

Adding sql reporting services feature

2012-12-16 Thread Joseph L. Casale
I have an SQL2008R2 server that is fully patched and I need to add the reporting
services feature. As the base media only comes in GA, I had a quick look at what
it takes to make slipstreamed media and frankly it looks like a hack.

Anyone actually do this in production or is the only supported method to add the
feature then reapply sp2?

Thanks!
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: SemiOT #2: More on SAMBA 4.0

2012-12-11 Thread Joseph L. Casale
 I am curious on what the list thinks about an open-source alternative to an 
 Active Directory
 server means to them... I'm sure many here will shrug it off, but for smaller 
 installs where
 money is tight, would you consider Samba 4.0 AD servers?

 I know I am.

First off, I'll state I am not a fan boy, I like MS and FOSS products equally, 
I run Linux both at
home and work on my desktop.

That being said, and with you assuming I might have a preference to Linux and 
Unix, I wouldn't
consider such a thing. The first support need your client will face without you 
being on hand
will cost more than the one time hit of an SBS or similar rollout. None of that 
abomination that
is called Samba is supported by any of your client OS's vendor and lets face 
it, Linux admins
are more difficult to find than a generic point-and-clicker that can still 
troubleshoot simple things.

I have such a distaste for Samba from setting up printing *with server supplied 
drivers* back in
the 3x days. Has 4 improved on that God awful abomination of a process?

jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: File Services Clustering in Server 2012

2012-12-06 Thread Joseph L. Casale
 Yep setting up a cluster just to protect against a service dying is overkill.

I think that statement might be a bit to general. What if that service doesn't
simply restart and 2500 people have their work impacted for 4 hours while
its resolved? 2500*$30*4=$300,000.00 as an example...

Does that application cluster investment still sound unrealistic?
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: iSCSI with HP/Brocade switches

2012-11-16 Thread Joseph L. Casale
Jumbos on 10GBe can actually slow things down, but everybody things
jumbo==sounds good therefor must be. There are a few technical reasons
why it doesn't improve generally at those speeds.

Some switches need certain characteristics disabled for that type of traffic.

Call HP, its free for those switches and ask what they suggest. I don't know
your switch specifically but before I throw the towel in, I'd give it a good 
shot.

jlc

From: Matthew W. Ross [mr...@ephrataschools.org]
Sent: Friday, November 16, 2012 10:49 AM
To: NT System Admin Issues
Subject: iSCSI with HP/Brocade switches

Hey List.

I have our new Dell/Equalogic vSphere cluster up and running, but we have been 
having some issues as of late with latency on switch side of the equation.

When we set up the cluster, we decided to use a pair of HP 2910al-24G switches. 
These were not the switches recommended by our VMWare vendor (They recommended 
a pair of Brocade 6610 switches). Now that we have been having these latency 
issues, we are considering the recommended switches.

So here's my questions:

1) Has anybody used HP switches (2910al-24s or similar) as the iSCSI transport? 
Has anyone seen similar issues, or are there some specific configurations that 
need to be double-checked?

2) Anybody seen any issues with the Brocade switches? (I expect the answer to 
be no, but it's never too late/early to ask.)


--Matt Ross
Ephrata School District

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Anyone have an idea on this one

2012-11-12 Thread Joseph L. Casale
Start the application as an Administrator? runas for example or right click 
it... 

From: Ziots, Edward [ezi...@lifespan.org]
Sent: Monday, November 12, 2012 7:09 AM
To: NT System Admin Issues
Subject: RE: Anyone have an idea on this one

Sorry its Windows 2008 SP2 not R2 SP1.

Z

Edward E. Ziots, CISSP, Security +, Network +
Security Engineer
Lifespan Organization
ezi...@lifespan.org


-Original Message-
From: Ziots, Edward [mailto:ezi...@lifespan.org]
Sent: Monday, November 12, 2012 9:08 AM
To: NT System Admin Issues
Subject: Anyone have an idea on this one

All,

I have a Windows 2008 R2 Sp1 server, in which even if I am local
administrator rights and the Local Administrator has full control to the
root of the drive, I can not save any files to the root of the drive.

Is this something with UAC? Or otherwise?

Please advise, I have even tried to re acl the drive with cacls d: /T /E
/C /G administrators:F and still didn't work.

Kinda of time sensitive,

Z

Edward E. Ziots, CISSP, Security +, Network + Security Engineer Lifespan
Organization ezi...@lifespan.org


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: DNS?

2012-10-28 Thread Joseph L. Casale
I have added a new Forward lookup zone for IMCU.COM on my local active 
Directory.
I have added an ‘a’ record for 10.0.50.4 for mail.imcu.com  in that zone.
I do not resolve the mail to the ip.
If I add that record in my hosts file I can browse it easily.
What is wrong in my DNS set up?
Server 2003 active directory.

Recycle the dnscache service. If you looked it up before your new fwd zone was
instantiated, your dns server returned a failure response and it was cached.

The hosts file lookup doesn't use this.

This does assume your client is using that dns server and it and the zone are 
setup
correctly...
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: System/file monitoring

2012-09-24 Thread Joseph L. Casale
I have to be honest, I wouldn't pay for such a thing.
A quick look has me guessing windows can provide all this info natively. 
Enabling
auditing for example and use a query to mine the relevant info. If you needed 
to act
on a file system event, there is the file system watcher class which you can 
leverage
either yourself or through some opensource implementations that allow you to 
run the
watcher as a service.

Is what your after just logging for accountability?

jlc

From: Ray [rz...@qwest.net]
Sent: Monday, September 24, 2012 2:09 PM
To: NT System Admin Issues
Subject: System/file monitoring

I tried a trial version of this: http://www.poweradmin.com/file-sight/ =
which seems to do what I need.  I have a lot of users I can't necessarily
trust, not to mention just being careless. Anyway, what this does is just
keep an eye on the folders and files to see who's creating, deleting or
moving them.

Just curious if anyone's using something better.

TIA


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: System Center 2012 Endpoint Protection

2012-09-24 Thread Joseph L. Casale

Are you talking about 2007 or 2012?

2012

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: System/file monitoring

2012-09-24 Thread Joseph L. Casale
Auditing has been enabled. The MS logfiles are just too chatty. But
filesystemwatcher looks interesting. Thanks.

That's why you need to extract what you are looking for:) Once you decide
what it is that interests you, you can script it and automate it.

The interface actually provides a means to filter them to help you decide. 
Create
a custom view, get it right than switch to the xml view and see how its done.

Now you can automate it, if you want a sample let me know.

jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: System Center 2012 Endpoint Protection

2012-09-23 Thread Joseph L. Casale
Anders,
Just started playing around with this in a lab scenario. Did you install all 
roles including WSUS on this single server?
When I get around to deploying this in production, I have an existing WSUS 
server, but in reality I wouldn't object to decommissioning it as a result of 
setting it all up on this single server.

That also being said, I may setup SQL on its own server just for the sake of 
forward thinking...

Thanks!
jlc


From: Anders Blomgren [chanks...@gmail.com]
Sent: Friday, September 21, 2012 2:21 AM
To: NT System Admin Issues
Subject: Re: System Center 2012 Endpoint Protection

Run it that way here, 200 managed computers. SCCM 2012 is the first version I'd 
even consider using for such a small environment. Still need 16GB ram though...

-Anders

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: System Center 2012 Endpoint Protection

2012-09-20 Thread Joseph L. Casale
In a super small environment, can you get away with the app and sql server on 
the same host?
They give it away free in OpenValue.

jlc

From: Brian Desmond [br...@briandesmond.com]
Sent: Thursday, September 20, 2012 3:34 PM
To: NT System Admin Issues
Subject: RE: System Center 2012 Endpoint Protection

Same here - multiple happy customers.

Thanks,
Brian Desmond
br...@briandesmond.com

w - 312.625.1438 | c   - 312.731.3132

-Original Message-
From: Michael B. Smith [mailto:mich...@smithcons.com]
Sent: Wednesday, September 19, 2012 4:57 PM
To: NT System Admin Issues
Subject: RE: System Center 2012 Endpoint Protection

It's a  very good solution. I've got it deployed with several different clients 
and it gets positive reviews all 'way round.

-Original Message-
From: Matthew W. Ross [mailto:mr...@ephrataschools.org]
Sent: Wednesday, September 19, 2012 5:23 PM
To: NT System Admin Issues
Subject: System Center 2012 Endpoint Protection

Hey Guys.

I'm looking at System Center 2012 Endpoint Protection (What a mouthful). 
Anybody using this? Anybody like/dislike it compared to other solutions?


--Matt Ross
Ephrata School District

~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin




~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: KMS at non-server sites?

2012-09-17 Thread Joseph L. Casale
Set the values in the registry for the kms host.
I do this for several PC's that I dont even join to the domain as a result of 
the lack of control.

This works for Office and Windows.

I then have a vpn for these with acl's that allow the required traffic and a 
script which refreshes activation.

jlc


From: Tom Miller [tmil...@hnncsb.org]
Sent: Monday, September 17, 2012 6:52 AM
To: NT System Admin Issues
Subject: KMS at non-server sites?

Hi Folks,

I have a number of sites with 2-5 PCs/laptops.  The devices were originally 
imaged and used our internal KMS server.  They are beginning to fail to 
check-in to the licensing server.

These sites are all connected via a VPN appliance (SOHO firewall to corp 
firewall).   The only traffic traversed the VPN is from the copier, for 
automatic notifications and messages to the SMTP server here.

These remote machines are not in the domain.  Is there a best practice for 
activation renewal?  Modify local host file?  Public DNS entry for the KMS 
server?  Convert to MAK?  I see a number of suggestions on the web and am 
looking for what works for you.

Thanks,
Tom


Confidentiality Notice: This e-mail message, including attachments, is for the 
sole use of the intended recipient(s) and may contain confidential and 
privileged information. Any unauthorized review, use, disclosure, or 
distribution is prohibited. If you are not the intended recipient, please 
contact the sender by reply e-mail and destroy all copies of the original 
message.

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Accessing powershell variables from within a scriptblock

2012-09-17 Thread Joseph L. Casale
Lol,
Simple solution, I've done it a couple times already. I bet if I hold off a
bit and wait for the next request, I can refactor this and the next in one
shot and kill two stones with one bird:)

From: Michael B. Smith [mich...@smithcons.com]
Sent: Monday, September 17, 2012 12:45 PM
To: NT System Admin Issues
Subject: RE: Accessing powershell variables from within a scriptblock

Just rewrite the darned thing. :-P

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Accessing powershell variables from within a scriptblock

2012-09-16 Thread Joseph L. Casale
The scriptblock that contains them is inside the script, when you call this 
script, it uses it
in the scriptblock parameter to Invoke-Command.

In this scriptblock, there are several variables, most of which only make sense 
remotely as
some are computed, but there are a few that the user may need to edit.

I should have passed these in as args so all of this would have been easy.

From: Ken Schaefer [k...@adopenstatic.com]
Sent: Sunday, September 16, 2012 8:39 PM
To: NT System Admin Issues
Subject: RE: Accessing powershell variables from within a scriptblock

Where are the user defined variables coming from? Do they only exist on the 
remote host?

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Accessing powershell variables from within a scriptblock

2012-09-15 Thread Joseph L. Casale
Hey Michael,

[ScriptBlock]$MySB = `
{
$Common = @{
VarA = 'something'
VarB = 'something_else'
}
...
}

Problem is that there is actual code that follows so invoking it would break 
the script that contains it and later sends it out as a job.
I was hoping to perform some validation on the various variables without some 
arcane string processing and regexing.

Thanks!
jlc


From: Michael B. Smith [mich...@smithcons.com]
Sent: Saturday, September 15, 2012 6:59 PM
To: NT System Admin Issues
Subject: RE: Accessing powershell variables from within a scriptblock

Give me an example.

Sent from my Windows Phone

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: ESXi and an HP switch

2012-08-22 Thread Joseph L. Casale
 Port groups can override vswitch
 config, I am guessing your pg that the vmk port resides in is not inheriting 
 the
 config you expect...

 Not sure what you mean by this.

Look at your vSwitch properties, you will see in Configuration: a vSwitch and 
one or
more Port Groups. They all have the same options as the vSwitch, so if any are
enabled/defined, it overrides the vSwitch.

 Thanks for walking through this with me, 'tis much appreciated.

No problem,
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: ESXi and an HP switch

2012-08-22 Thread Joseph L. Casale
That was it. I looked at the properties of the management port group,
and it had not inherited the IP HASH setting. Once I manually set
that, it worked.

I'm setting up iSCSI connections and etc. now.

Thank you!

No problem,
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Recovering formatted drive

2012-08-21 Thread Joseph L. Casale
  First, before doing **ANYTHING** else, make a block-level copy of
 the physical disk to a file on another (bigger) filesystem.  Under a
 nix, the command would be something like:

And after you get that, the best tool I have found for this very case is
http://www.cgsecurity.org/wiki/TestDisk
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: ESXi and an HP switch

2012-08-21 Thread Joseph L. Casale
 went back to the article linked above, and set up NIC teaming with IP
HASH and made sure that all four NICs were active, then tried setting
up the trunk again, and again had no success.

Does anyone have thoughts regarding what I might be missing?

I'm looking at two esxi servers done this very way with an HP as well.

The Route based on IP hash with trunk not LACP mode is well doc'ed for
procurves. I then have all the exposed vlans tagged on the HP. Finally, the
port groups are each tagged into their respective vlan.

Each server has the vmk port in its own vswitch tagged into the esxi mgmt
vlan as well. So mgmt, storage, various production traffic is all segmented.

One thing I had to do was set the duplex on all the interfaces to G/full. No
matter the vendor, Intel and Broadcoms all needed this...

hth,
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: ESXi and an HP switch

2012-08-21 Thread Joseph L. Casale
I'm not sure it does, but I'll try setting the duplex/speed statically
on the switch and server and see if that gets me anywhere.

It is in the vmware NIC config where I had to set it.

Below are two configs of the switch - one that has trunking but
doesn't work, and the other that doesn't have trunking but does work -
the configuration of the server is the same for each - a single
vswitch with the management network and VM network on it. This machine
has no local storage, it's booting from flash, so there are no VMs
yet. Just the four active NICs set up with teaming based on IP HASH.

So you loose connectivity when you trunk, can you describe the complete
Networking topology setup, If you haven't any guests, I assume you are only
attempting to base connectivity off the vmk port. Port groups can override 
vswitch
config, I am guessing your pg that the vmk port resides in is not inheriting the
config you expect...

Other things to check:

Whats your Security settings on the vswitch (pg's)?

Its possible you have a setting on the physical switch which is problematic, 
enable
debug in a separate console and enable the trunk and see what happens.

jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: PS export question

2012-08-07 Thread Joseph L. Casale


Format-Table doesn't play nice with the pipeline past itself.

Simply put, ft/fl are for viewing data.
http://technet.microsoft.com/en-us/library/dd347677.aspx

Windows PowerShell has a set of cmdlets that allow you to control which 
properties are
displayed for particular objects. The names of all the cmdlets begin with the 
verb Format.
They let you select one or more properties to show.

Its not meant to format output for writing to a file, though some incarnations 
work, sort of...

jlc





~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell XML issue

2012-08-07 Thread Joseph L. Casale
 There’s an InnerXml property on there that might be useful?

Turns out the the serialization/deserialization that happens to some types in 
remoting
strips the methods, I rewrote without using attrs to prevent this. That was a 
tough lesson
late in this exercise :(
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell XML issue

2012-08-07 Thread Joseph L. Casale
Some time ago I read an interesting essay to the effect of, Is the
thing you're sending across the wire much more complex than a string?
Then you have failed; go buy another subscription to MSDN.  It
doesn't apply all the time, but it's always good food for thought when
I find myself starting to get carried away with some newfangled
software stack to pass messages between processes.

Hah, thats good...
Yeah, next one on the plate is messaging queuing daemon with native interfaces 
for
Linux (python) and Windows (.Net), this hard lesson should keep me on the 
straight
and narrow:)

jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Internet Monitoring

2012-07-04 Thread Joseph L. Casale
The FreeBSD/Squid/Apache box I had running didn't have these problems,
but the manager wanted something with commercial support.

echo FreeBSD/Squid/Apache |sed 's|FreeBSD|RHEL|' == Commercial Support :)

Sorry, couldn't resist...
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Internet Monitoring

2012-07-04 Thread Joseph L. Casale
Nope - that's almost reasonable...

But he's a Windows bigot to boot - doesn't want us messing with
non-MSFT operating systems at all.

I am certainly not a fanboy of either, right tool right job, I like em both... 

I don't know much about the appliance, but I can safely assume what it runs:)

To bad for you, usually when I encounter a bigot of either, we both know where 
that
comes from...
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: in-depth AD

2012-06-16 Thread Joseph L. Casale
I have most stuff at home – this is what the one ESX box looks like right now:

What specs do you run that long list on at home?

Thanks!
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



Re: in-depth AD

2012-06-15 Thread Joseph L. Casale
Ken,
How do you find the proc on those things, I assumed it was far to  
under sized for exchange and ad etc. Also, what's the KVM usability  
like on the rac?

Thanks!
jlc

On Jun 15, 2012, at 4:19 AM, Ken Schaefer k...@adopenstatic.com  
wrote:

 To be honest, when HP N40L Microservers are $350 each, everyone  
 should be able to afford a lab.

 The HP specs say that they only take 8GB of RAM each, but you can  
 run them at 16GB of RAM. They have 4 built-in 3.5 drive bays, and  
 space for 2 more drives.

 They are really quiet and compact. And you can install a remote  
 access card if you want (about $80)

 I run 2 of these now: both with 16GB of RAM, 2 x 128GB SSD + 2 x 2TB  
 drives, remote access cards, plus an additional add-in NIC. You can  
 run a lot of VMs on that

 Disclaimer: I work for HP.

 Cheers
 Ken

 -Original Message-
 From: Ben Scott [mailto:mailvor...@gmail.com]
 Sent: Thursday, 14 June 2012 1:43 AM
 To: NT System Admin Issues
 Subject: Re: in-depth AD

 On Wed, Jun 13, 2012 at 9:24 AM, Daniel Chenault dchena...@lgnetworksinc.com 
  wrote:
 A lab.. nice. You have one? Wish I did. I lack the hardware to set  
 one up.

  Someone on one of these lists once remarked to that kind of
 situation: Actually, you do have a test environment.  What you do  
 not have is a production environment.

 -- Ben

 ~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~  
 http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

 ---
 To manage subscriptions click here: 
 http://lyris.sunbelt-software.com/read/my_forums/
 or send an email to listmana...@lyris.sunbeltsoftware.com
 with the body: unsubscribe ntsysadmin

 ~ Finally, powerful endpoint security that ISN'T a resource hog! ~
 ~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

 ---
 To manage subscriptions click here: 
 http://lyris.sunbelt-software.com/read/my_forums/
 or send an email to listmana...@lyris.sunbeltsoftware.com
 with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Dynamic ScriptBlock creation

2012-06-11 Thread Joseph L. Casale
Much appreciated, it must have been a case of staring at the whole mess for too 
long.
I soon resolved the variable expansion, but then cleaned it all up by passing 
both hashes
in as args and resolving internal to the dynamic script once at the remote host.

Lots of nuances associated with remoting, especially related to getting results 
back at the
originating console, its been an adventure.

Thanks!
jlc


From: Michael B. Smith [mich...@smithcons.com]
Sent: Monday, June 11, 2012 7:14 AM
To: NT System Admin Issues
Subject: RE: Dynamic ScriptBlock creation

If you have a hash-table (or any variable that uses text as a 'getter' for the 
enumerator) you can use single or double quotes to work around PowerShell's 
variable naming conventions. If you are inside a double-quoted here-string, 
variable expansion still happens in single quotes located inside the string. So:

$objectName = 'someHashTable'
$valueName = 'some-Value-Name'
$resultName = 'resultVariable'

$here =  `$$resultName = `$$objectName.'$valueName'

If you need even more extreme naming conventions, consider this naming form for 
your variables, which can also be used to access methods and properties and 
special types:

${This is a Valid VaRiAbLe Name, with brace decorations!} = 1

-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Friday, June 08, 2012 9:16 PM
To: NT System Admin Issues
Subject: RE: Dynamic ScriptBlock creation

The problem stemmed from the fact that I have several modes or operations that 
a script may run against several servers. Almost all of the different 
operations required some base set of config to be derived by executing various 
queries on the remote servers locally.

All of these jobs required a load of config to be passed into them, I wrapped 
invoke-command in a loop that read hosts and their unique attributes from a 
file then spawned the jobs.

Some of these jobs required state information to be passed between them, but I 
could not execute the sequence all at once unless each stage was successful on 
each node. If a node had an issue, manual intervention would be required 
otherwise any node that proceeded would cause the nodes not passing checks to 
be invalid and the clusters would be destroyed. So each step has to be invoked 
manually.

I also write state info the successive jobs need to an xml file...

Burden came when developing the script, the script blocks for each stage reused 
code and every change required amending each script block. So I split them into 
separate files, set them to vars, and sourced them in one small script which 
then assembled them all including the params and state info into one large 
script block that is sent to to each node, the single arg passed in then 
invokes the required function.

Thats how I arrived at the exact example I posted, vars changed as they were 
meaningless.

If I use single quotes, how do I perform the substitution? I am also not sure 
what you mean by decorated variables, a small nudge would be very appreciated:)

Thanks!
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Friday, June 08, 2012 6:49 PM
To: NT System Admin Issues
Subject: RE: Dynamic ScriptBlock creation

There are likely 2 or 3 ways to address this (using single quotes or decorated 
variables), but I'd really like to see an real-world example, 'cuz it's not 
clear to me what you are trying to accomplish.

And, by the way, scriptblocks are always serialized as strings - so you may not 
actually be helping yourself.
~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Dynamic ScriptBlock creation

2012-06-11 Thread Joseph L. Casale
Heh,
I wouldn't know where to begin:)

You need to write output to stdout to be able to receive it, obviously their is 
no Host for this remote job
in terms of the remote script.

Get-Content is slow, File.IO doesn't seem to handle open log files, 
IO.FileStream can but has a lot more
overhead in terms of the code to execute it.

Obviously when you are managing several concurrent jobs across many hosts, you 
have a lot of explicit
scenario checking in obviously different ways to create good feedback of what 
is going on. This has been
a fun one...

jlc

From: Webster [webs...@carlwebster.com]
Sent: Monday, June 11, 2012 7:50 AM
To: NT System Admin Issues
Subject: Re: Dynamic ScriptBlock creation

Sounds like someone needs to write up what they just learned. :)  iow,
share your new knowledge.


Carl Webster
Consultant and Citrix Technology Professional
http://www.CarlWebster.com http://www.carlwebster.com/
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Dynamic ScriptBlock creation

2012-06-11 Thread Joseph L. Casale
Get-content -readcount 0  -- MUCH faster.

Me thinks you mean a number higher than 0 right?

Eventing makes this kind of thing much easier.

Right except that this log is perpetually growing. How would eventing assist on 
this one?
As far as I know, I might be alerted to it having changed, but knowing where to 
start reading
from as something I am not aware can be done?

Thanks!
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



Dynamic ScriptBlock creation

2012-06-08 Thread Joseph L. Casale
To overcome some difficulties in passing args and combining script blocks to be 
sent to
multiple hosts, I am using [ScriptBlock]::Create() on a few existing 
ScriptBlocks and one
text here string to populate variables in the ScriptBlock instead of passing 
args.

My issue is expanding certain variable types in the here string:

This doesn't work, only $var1 expands out to create a valid string 
representation of a ScriptBlock
for later conversion:

$ScriptBlockArgs = @
  `$foo = `$PSCustomObject.KeyName`
  `$bar = `$var1`
@

This does work, but is likely unnecessary:

$var0 = $Node.Instance-Name
$ScriptBlockArgs = @
  `$foo = `$var0`
  `$bar = `$var1`
@

I realize the double quotes on KeyName are an issue, but I have tried 
everything I can think
of to escape or pre expand it without success. It also bails when trying to 
assign a hash table
into a new variable.

Anyone have any ideas?
Thanks.
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Dynamic ScriptBlock creation

2012-06-08 Thread Joseph L. Casale
The problem stemmed from the fact that I have several modes or operations that 
a script
may run against several servers. Almost all of the different operations 
required some base
set of config to be derived by executing various queries on the remote servers 
locally.

All of these jobs required a load of config to be passed into them, I wrapped 
invoke-command
in a loop that read hosts and their unique attributes from a file then spawned 
the jobs.

Some of these jobs required state information to be passed between them, but I 
could not
execute the sequence all at once unless each stage was successful on each node. 
If a node
had an issue, manual intervention would be required otherwise any node that 
proceeded would
cause the nodes not passing checks to be invalid and the clusters would be 
destroyed. So
each step has to be invoked manually.

I also write state info the successive jobs need to an xml file...

Burden came when developing the script, the script blocks for each stage reused 
code and
every change required amending each script block. So I split them into separate 
files, set them
to vars, and sourced them in one small script which then assembled them all 
including the params
and state info into one large script block that is sent to to each node, the 
single arg passed in then
invokes the required function.

Thats how I arrived at the exact example I posted, vars changed as they were 
meaningless.

If I use single quotes, how do I perform the substitution? I am also not sure 
what you mean by
decorated variables, a small nudge would be very appreciated:)

Thanks!
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Friday, June 08, 2012 6:49 PM
To: NT System Admin Issues
Subject: RE: Dynamic ScriptBlock creation

There are likely 2 or 3 ways to address this (using single quotes or decorated 
variables), but I'd really like to see an real-world example, 'cuz it's not 
clear to me what you are trying to accomplish.

And, by the way, scriptblocks are always serialized as strings - so you may not 
actually be helping yourself.
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



Invoke-Command and multiple ScriptBlocks

2012-06-07 Thread Joseph L. Casale
I have a series of files I source that contain scriptblocks assigned to a 
variable. In my script I
am referencing these vars as the argument to -ScriptBlocks and as I have not 
found a way to
used named arguments my scriptblock param set uses positional references.

Now the issue is several scriptblocks share some code, so I am at a loss as to 
pass in args
if I use which ever technique to combine them before passing it into 
Invoke-Command how do
you handle the args now?

Anyone know how to pass named args into Invoke-Command?

Thanks!
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell and dos batch

2012-06-06 Thread Joseph L. Casale
From a DOS shell, type `powershell.exe -?` and you'll see how to invoke a 
session with a script and all the other options which may need to apply.

jlc

From: itli...@imcu.com [itli...@imcu.com]
Sent: Wednesday, June 06, 2012 10:07 AM
To: NT System Admin Issues
Subject: Powershell and dos batch

I have need to running a powershell script for Backup Exec 2012 through a DOS 
batch file.
Here is what I have so far:


::Batch File
::powershell

C:\windows\system32\WindowsPowerShell\v1.0\powershell.exe 
'e:\in01\oper\task\BackupJob.ps1'
exit
___
BackupJob.ps1
Import-Module BEMCLI | Get-BEJob -Name BackupJob-Full | Start-BEJob | exit


Where the BackupJob is already set up in the GUI library on the server.
I get nothing.
The batch file just finishes.
I put a pause after it and I see no errors?
So what am I doing wrong and how do I make it work?
Thanks


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Powershell and dos batch

2012-06-06 Thread Joseph L. Casale
How did you determine that?

From: Miller Bonnie L. [mille...@mukilteo.wednet.edu]
Sent: Wednesday, June 06, 2012 12:47 PM
To: NT System Admin Issues
Subject: RE: Powershell and dos batch

Do they require Powershell v2?  I see you are using v1.0.

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Powershell and dos batch

2012-06-06 Thread Joseph L. Casale
Language Engine version and Windows Powershell version are two different things.
Its all Language Engine version 1 for all three Windows Powershell versions.

From: Miller Bonnie L. [mille...@mukilteo.wednet.edu]
Sent: Wednesday, June 06, 2012 2:49 PM
To: NT System Admin Issues
Subject: RE: Powershell and dos batch

Ah, did not know that!  I wonder who thought up that gem?  =)

From: Damien Solodow [mailto:damien.solo...@harrison.edu]
Sent: Wednesday, June 06, 2012 12:47 PM
To: NT System Admin Issues
Subject: Re: Powershell and dos batch

Actually all current powershell versions (including the forthcoming 3.0) 
install in that path.

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Powershell PSCustomObject

2012-06-05 Thread Joseph L. Casale
That would be affirmative:)

From: Michael B. Smith [mich...@smithcons.com]
Sent: Tuesday, June 05, 2012 5:17 AM
To: NT System Admin Issues
Subject: RE: Powershell PSCustomObject

Not a programmer, huh? :-)

You can do this with filters, but it wouldn't be any easier.
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



Powershell PSCustomObject

2012-06-04 Thread Joseph L. Casale
How does one iterate through all values in a  PSCustomObject? For example, if 
you import a csv, then iterate through the resulting array, each element is a 
PSCustomObject and you can access each element by name (the header in the csv) 
but how do you blindly iterate them all to test for a null value for example?
Thanks!
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell PSCustomObject

2012-06-04 Thread Joseph L. Casale
Hrm,
I must be doing something wrong then.

If I call out the individual item and test it works:

If ($obj.foo -eq $null) { bail }

I gather the method you show tests if the entire psobject is null, whereas if 
only one of the NoteProperty are empty, it won't fail the test?

Thanks!
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Monday, June 04, 2012 6:09 PM
To: NT System Admin Issues
Subject: RE: Powershell PSCustomObject

$obj |? { $_ -ne $null } | ...
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell PSCustomObject

2012-06-04 Thread Joseph L. Casale
Sorry Michael,

$Config = Import-Csv -Path somefile.csv

The csv may look like:
A,B,C,D
foo,bar,biz,baz
foo,bar,baz

So I should expect to a see a NoteProperty for A,B,C and D on both lines but 
testing for $Config[0].A through D etc is tedious and if the CSV file is 
expanded the test has to be updated.
This is certainly easier with a hash...

Thanks!
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Monday, June 04, 2012 7:24 PM
To: NT System Admin Issues
Subject: RE: Powershell PSCustomObject

Well then perhaps you should provide a more substantive example. :-P
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell PSCustomObject

2012-06-04 Thread Joseph L. Casale
Well this was by no means obvious:

Foreach ($Line in $Config)
{
Foreach ($Entry in $Line.psobject.properties)
{
If ($Entry.Value -eq $null)
{
Return $False
}
}
}

jlc

From: Joseph L. Casale [jcas...@activenetwerx.com]
Sent: Monday, June 04, 2012 7:45 PM
To: NT System Admin Issues
Subject: RE: Powershell PSCustomObject

Sorry Michael,

$Config = Import-Csv -Path somefile.csv

The csv may look like:
A,B,C,D
foo,bar,biz,baz
foo,bar,baz

So I should expect to a see a NoteProperty for A,B,C and D on both lines but 
testing for $Config[0].A through D etc is tedious and if the CSV file is 
expanded the test has to be updated.
This is certainly easier with a hash...

Thanks!
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



Powershell question

2012-05-30 Thread Joseph L. Casale
I often have scripts I write that involve passing potentially different sets of 
commands to
cmdlets based on switches I pass to the script. Some provide built in means to 
make it
easy:

 -Verbose:($PSBoundParameters['Verbose'] -eq $true)

In the case where I need to invoke a binary, I push the extra arg into the 
array list passed
to the System.Diagnostics.Process job as the arglist. Works well.

If I am simply running a cmdlet:

 Some-Cmdlet `
   -Param1 xxx `
   -Param2 xxx

If I tack another back tick on param2, what powershell foo allows a conditional 
3rd param to
be passed? Would be so much tidier than if/else and duplicating the whole thing.

Thanks!
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Job (batch) control software

2012-05-30 Thread Joseph L. Casale
The built in scheduler?
Can be accessed programmatically several ways and offers a good amount of knobs 
to twist?

From: David L Herrick [davidherr...@nincal.com]
Sent: Wednesday, May 30, 2012 3:03 PM
To: NT System Admin Issues
Subject: Job (batch) control software

We utilize 2 lowly workstations to run recurring jobs and jobs submitted by our 
in house applications.

We have used a defunct product Lanbatch32 for years. We had to work around some 
issues to make it work under Windows 7 and it will not run at all in a 64bit 
environment.

My google fu has failed me I only seem to find very expensive high end products 
or products designed for a single computer/user .  Any suggestions?


thanks

David L. Herrick
Chief Financial Officer
Executive Vice President

510.302.4606
www.namesinthenews.comhttp://www.namesinthenews.com

Facebookhttp://www.facebook.com/namesinthenews | 
Twitterhttp://twitter.com/#!/inga_nin

[Description: Logo color box only (email)]


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmininline: image003.jpg

RE: Job (batch) control software

2012-05-30 Thread Joseph L. Casale
http://msdn.microsoft.com/en-us/library/bb756979.aspx

http://taskscheduler.codeplex.com/

http://letitknow.wordpress.com/2011/05/20/create-scheduled-task-by-using-powershell/

Or use schtasks.exe

From: David L Herrick [davidherr...@nincal.com]
Sent: Wednesday, May 30, 2012 3:19 PM
To: NT System Admin Issues
Subject: RE: Job (batch) control software

MMM can you point me towards access points?

API calls?

I guess we could get used to the MS interface for monitoring what is going on. 
Have not looked that closely at its flexibility  IE we want job A to run Monday 
-  Friday between 7am and 6 pm every hour




From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Wednesday, May 30, 2012 2:11 PM
To: NT System Admin Issues
Subject: RE: Job (batch) control software

The built in scheduler?
Can be accessed programmatically several ways and offers a good amount of knobs 
to twist?

From: David L Herrick [davidherr...@nincal.com]
Sent: Wednesday, May 30, 2012 3:03 PM
To: NT System Admin Issues
Subject: Job (batch) control software
We utilize 2 lowly workstations to run recurring jobs and jobs submitted by our 
in house applications.

We have used a defunct product Lanbatch32 for years. We had to work around some 
issues to make it work under Windows 7 and it will not run at all in a 64bit 
environment.

My google fu has failed me I only seem to find very expensive high end products 
or products designed for a single computer/user .  Any suggestions?


thanks

David L. Herrick
Chief Financial Officer
Executive Vice President

510.302.4606
www.namesinthenews.comhttp://www.namesinthenews.com

Facebookhttp://www.facebook.com/namesinthenews | 
Twitterhttp://twitter.com/#!/inga_nin

[Description: Logo color box only (email)]


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmininline: image001.jpg

RE: Powershell question

2012-05-30 Thread Joseph L. Casale
Actually, you are right about the -verbose, I forgot about that and simply 
opened up the first script.
CmdletBinding enables all cmdlets to produce the output if they provide...

I am not following you on the  operator for the Some-Cmdlet example. I did try 
invoke-expression
without luck, if its the right way I will revisit it and figure out what I did 
wrong.

As for running a binary, why is my method flawed (brief idea here)?

$Args = New-Object System.Collections.ArrayList
[void]$Args.Add(--log-file=path)
[void]$Args.Add(--recursive)
...
If ($PSBoundParameters['Verbose'])
{
[void]$Args.Add(--verbose)
[void]$Args.Add(--stats)
}
If ($Checksum)
{
[void]$Args.Add(--checksum)
}

$Process = New-Object System.Diagnostics.Process
$Process.StartInfo.FileName = $BinPath\rsync.exe
$Process.StartInfo.Arguments = $Args


This works pretty well and takes care of a *myriad* of shell escaping as 
System.Diagnostics.Process
does all the heavy lifting?

Thanks!
jlc


From: Michael B. Smith [mich...@smithcons.com]
Sent: Wednesday, May 30, 2012 4:41 PM
To: NT System Admin Issues
Subject: RE: Powershell question

You need to take a look at the  operator and the invoke-command and 
invoke-expression cmdlets.

Insofar as push the extra arg into the array list YUCK. Check out 
Start-Process and Wait-Process.

The way you are using Verbose isn't the way it's MEANT to be used (although 
what you are doing certainly does work). All you need to do is set 
CmdletBinding as the master attribute on the parameter list.

-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Wednesday, May 30, 2012 4:55 PM
To: NT System Admin Issues
Subject: Powershell question

I often have scripts I write that involve passing potentially different sets of 
commands to cmdlets based on switches I pass to the script. Some provide built 
in means to make it
easy:

 -Verbose:($PSBoundParameters['Verbose'] -eq $true)

In the case where I need to invoke a binary, I push the extra arg into the 
array list passed to the System.Diagnostics.Process job as the arglist. Works 
well.

If I am simply running a cmdlet:

 Some-Cmdlet `
   -Param1 xxx `
   -Param2 xxx

If I tack another back tick on param2, what powershell foo allows a conditional 
3rd param to be passed? Would be so much tidier than if/else and duplicating 
the whole thing.

Thanks!
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell question

2012-05-30 Thread Joseph L. Casale
I didn't use Wait-Process below because I want the exit value.

Did someone say exit code?

$Args = New-Object System.Collections.ArrayList
[void]$Args.Add(--Bad-Arg)
$Process = New-Object System.Diagnostics.Process
$Process.StartInfo.UseShellExecute = $false
$Process.StartInfo.RedirectStandardOutput = $true
$Process.StartInfo.RedirectStandardError = $true
$Process.StartInfo.FileName = C:\Windows\System32\ipconfig.exe
$Process.StartInfo.Arguments = $Args
[void]$Process.Start()
$Process.WaitForExit()
$ExitVal = $Process.ExitCode
$StdOut = $Process.StandardOutput.ReadToEnd()
$StdErr = $Process.StandardError.ReadToEnd()

$ExitVal
$StdOut

--

1

Error: unrecognized or incomplete command line.
/snip


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell Remote Job Management

2012-05-29 Thread Joseph L. Casale
Thanks guys,
The link from powershell.org was a short read, the methods gotcha was 
insightful but it didn't have much...

Checking out the new link...
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Tuesday, May 29, 2012 7:56 AM
To: NT System Admin Issues
Subject: RE: Powershell Remote Job Management

I was actually referring to this one:

http://powershell.com/cs/media/p/4908.aspx

But it appears the one at your link is newer. I'll have to take a look at it.

-Original Message-
From: Rod Trent [mailto:rodtr...@myitforum.com]
Sent: Tuesday, May 29, 2012 9:41 AM
To: NT System Admin Issues
Subject: RE: Powershell Remote Job Management

This one?

http://myitforum.com/myitforumwp/2012/04/27/free-ebook-secrets-of-powershell-remoting/





-Original Message-
From: Michael B. Smith [mailto:mich...@smithcons.com]
Sent: Monday, May 28, 2012 7:58 PM
To: NT System Admin Issues
Subject: RE: Powershell Remote Job Management

I recommend you read Administrator's Guide to Windows PowerShell Remoting
by Tobias Weltner.

Remoting is a complex topic.

-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Monday, May 28, 2012 7:38 PM
To: NT System Admin Issues
Subject: Powershell Remote Job Management

I am starting to write some framework for updating application clusters.
One thing I noticed is that the input for Invoke-Command can take an array for 
-ComputerName, which initially seems rather useful in determining when the 
batch is all done versus manually checking all of them, I only have to keep 
track of one job.

Any caveats to this? I presume the only one I can see initially is discerning 
what output belongs to which server when they all return and you Receive-Job?

Any insight from those who have been down this road would be appreciated...
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here:
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin




~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell Variables

2012-05-29 Thread Joseph L. Casale
Thanks guys.

From: Randal, Phil [phil.ran...@hoopleltd.co.uk]
Sent: Tuesday, May 29, 2012 8:59 AM
To: NT System Admin Issues
Subject: RE: Powershell Variables

$foo=”bar”
$bar=22

Invoke-expression  (“$”+$foo)

Cheers,

Phil

--
Phil Randal
Infrastructure Engineer
Hoople Ltd | Thorn Office Centre | Hereford HR2 6JT
Tel: 01432 260415 | Email: phil.ran...@hoopleltd.co.uk

From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: 29 May 2012 15:40
To: NT System Admin Issues
Subject: Powershell Variables

How does one leverage the evaluated output from some expression as the name of 
a new variable?

For example (simplified):

$foo = bar
$bar = 22

Write-host $$foo
 22

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

“Any opinion expressed in this e-mail or any attached files are those of the 
individual and not necessarily those of Hoople Ltd. You should be aware that 
Hoople Ltd. monitors its email service. This e-mail and any attached files are 
confidential and intended solely for the use of the addressee. This 
communication may contain material protected by law from being passed on. If 
you are not the intended recipient and have received this e-mail in error, you 
are advised that any use, dissemination, forwarding, printing or copying of 
this e-mail is strictly prohibited. If you have received this e-mail in error 
please contact the sender immediately and destroy all copies of it.

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

Classic break/continue issue in foreach loop

2012-05-29 Thread Joseph L. Casale
I have a collection of collections I need to iterate over: $_.Data |%{ Match, 
then break }

Problem is return/continue do not end the final iteration of objects, how does 
one effectively
accomplish this? $_.Data is actually a collection itself from a larger 
collection? Once I
match, there is no point in continuing to look, but the scope of break still 
appears global
so the script halts?

Thanks guys,
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Classic break/continue issue in foreach loop

2012-05-29 Thread Joseph L. Casale
I have a collection of collections I need to iterate over: $_.Data |%{ Match, 
then break }

Problem is return/continue do not end the final iteration of objects, how does 
one effectively
accomplish this? $_.Data is actually a collection itself from a larger 
collection? Once I
match, there is no point in continuing to look, but the scope of break still 
appears global
so the script halts?

I rectified this with a Where-Object and 'Select -First 1'

$_.Data |?{ $_.#text -iMatch $Filter } |
Select -First 1 |Out-Null
Increment totals...

Not so sure this the best way, but it works...
jlc


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Classic break/continue issue in foreach loop

2012-05-29 Thread Joseph L. Casale
After I sent the msg, I realized it only helped me not hit the code that
increments the counter more than once, but was equally as useless.

I still haven't figured out the break/continue/return as it applies to this
case, heh...

Thanks!

From: Michael B. Smith [mich...@smithcons.com]
Sent: Tuesday, May 29, 2012 1:48 PM
To: NT System Admin Issues
Subject: RE: Classic break/continue issue in foreach loop

The downside of that method is that it will evaluate all the items in the data 
block. If the data block is relatively small, it's not a big deal. Otherwise, 
I'd probably be looking at a different search mechanism.
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Classic break/continue issue in foreach loop

2012-05-29 Thread Joseph L. Casale
Thanks Michael,
I am so used to using % that sometimes I get hung up overlooking better ways
to do things.

Oh and no film site viewing, I am at work:)

Appreciate the patience,
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Tuesday, May 29, 2012 3:04 PM
To: NT System Admin Issues
Subject: RE: Classic break/continue issue in foreach loop

What you need is a lambda function with a begin and a process section.

Alternately, if that doesn't make sense to you, explode the loop.
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



Powershell Remote Job Management

2012-05-28 Thread Joseph L. Casale
I am starting to write some framework for updating application clusters.
One thing I noticed is that the input for Invoke-Command can take an array for
-ComputerName, which initially seems rather useful in determining when the
batch is all done versus manually checking all of them, I only have to keep
track of one job.

Any caveats to this? I presume the only one I can see initially is discerning 
what
output belongs to which server when they all return and you Receive-Job?

Any insight from those who have been down this road would be appreciated...
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



Powershell Eventlog Reporting

2012-05-24 Thread Joseph L. Casale
I need to extract several Security Group Management related events from the 
security log.
Using Get-EventLog leaves me with the Message and ReplacementStrings properties 
as strings.

So filtering on an OU and finally developing a non-admin friendly report that 
shows just a username
and group changes for example leaves me with string manipulation.

Anyone know any tricks to this?

Thanks!
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell Eventlog Reporting

2012-05-24 Thread Joseph L. Casale
Sorry Michael,
The Message is a string, which makes for large capturing regex's, total pain...
I had hoped the Member|Account name was accessible from with the Message
property...

An example output:

Get-WinEvent Security |?{ $_.Id -eq 4729 } |fl

TimeCreated  : 5/24/2012 9:40:16 AM
ProviderName : Microsoft-Windows-Security-Auditing
Id   : 4729
Message  : A member was removed from a security-enabled global group.
   
   Subject:
   Security ID:
S-1-5-21-2887164728-1639811974-4180998483-500
   Account Name:Administrator
   Account Domain:FOO
   Logon ID:0x332ab
   
   Member:
   Security ID:
S-1-5-21-2887164728-1639811974-4180998483-1109
   Account Name:CN=user,OU=1,OU=a,DC=foo,DC=local
   
   Group:
   Security ID:
S-1-5-21-2887164728-1639811974-4180998483-5135
   Group Name:Grp_Test
   Group Domain:FOO
   
   Additional Information:
   Privileges:-

From: Michael B. Smith [mich...@smithcons.com]
Sent: Thursday, May 24, 2012 10:10 AM
To: NT System Admin Issues
Subject: RE: Powershell Eventlog Reporting

I don't understand what you are asking?
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell Eventlog Reporting

2012-05-24 Thread Joseph L. Casale
Thanks guys.
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: SetACL Studio

2012-05-22 Thread Joseph L. Casale
I do, its my preferred tool...

From: Gene Giannamore [gene.giannam...@abideinternational.com]
Sent: Tuesday, May 22, 2012 12:33 PM
To: NT System Admin Issues
Subject: SetACL Studio

Just wondering if anyone uses this on a production server. I’m just testing it 
on a 08R2 file server.
http://helgeklein.com/setacl-studio/


--
Gene


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Wireless AP choice

2012-05-10 Thread Joseph L. Casale
All pfSense boxes, I'm afraid:)

They do have a captive portal, and I actually may use it for offloading the 
public task.

From: Richard Stovall [rich...@gmail.com]
Sent: Thursday, May 10, 2012 8:04 PM
To: NT System Admin Issues
Subject: Re: Wireless AP choice

What kind of firewall do you have?  I ask because the SonicWall wireless stuff 
is very simple to set up and puts the WiFi management right into the same 
familiar console where you manage the firewall.

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: CyberLink PowerDirector is a buggy piece of sh!t

2012-04-23 Thread Joseph L. Casale
  Well, since we're here... anyone have a recommendation for decent
non-linear video editing software which *doesn't* require one to take
out a second mortgage?

You qoute like a Linux vet, but don't think like one:) Their are a few good
ones for free in Linux.

Try VLMC...
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Automated Account Password Reset Programs

2012-04-17 Thread Joseph L. Casale
Hitachi-ID Password Manager.

From: Ziots, Edward [ezi...@lifespan.org]
Sent: Tuesday, April 17, 2012 12:27 PM
To: NT System Admin Issues
Subject: Automated Account Password Reset Programs

For those that are using this for your users in your orgs/business, can anyone 
give me an idea again what folks are using for Automated Password reset tools, 
that would integrate well with 2k8R2 DFL/FFL domain. About 18-20K in accounts. 
Looking for a solution with a Web front end, and the ability to customize the 
questions asked the users before they can reset there passwords.

Z

Edward Ziots
CISSP, Security +, Network +
Security Engineer
Lifespan Organization
ezi...@lifespan.org


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Powershell verbose pref

2012-04-11 Thread Joseph L. Casale
Yeah, problem is, the return that gets shoved into a variable appears to be an 
array of System.Object?
If I simply `$foo|ft -auto` I get a nice table, but I can't execute 
`Write-Verbose $foo` as a result of the System.Object type of its elements.
When I loop through element of the return, I am expecting a hash but I get 
system.management.automation.pscustomobject?

The output is the return of this function:

Function Get-StatementResult
{
Param
(
[System.Data.Odbc.OdbcConnection] $databaseHandle,
[String] $sql
)
$databaseCommand = New-Object System.Data.Odbc.OdbcCommand
$databaseCommand.Connection = $databaseHandle
$databaseCommand.CommandType = [System.Data.CommandType]::Text
$databaseCommand.CommandText = $sql
$reader = $databaseCommand.ExecuteReader()
$objectArray = @()
While ($reader.Read() -eq $True)
{
$hash = @{}
Foreach ($i in 0..($reader.FieldCount - 1))
{
$hash.$($reader.GetName($i)) = $reader.GetValue($i)
}
$objectArray += New-Object PSObject -property $hash
}
$databaseCommand.Cancel()
$databaseCommand = $null
Return $objectArray
}

Thanks!
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Wednesday, April 11, 2012 12:31 PM
To: NT System Admin Issues
Subject: RE: Powershell verbose pref

Have you taken a look at Write-Verbose ???

From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Wednesday, April 11, 2012 2:26 PM
To: NT System Admin Issues
Subject: Powershell verbose pref

I have a script where I simply piped a hash into a ft -auto to print it.
Now I am trying to only do this when the verbose flag is set and have all the 
lines prefixed with VERBOSE:.

Is there a simple way to do this, or must I test for verbose, then iterate 
through the hash?

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: OTish VPN tunnel on the quick and cheap.

2012-04-11 Thread Joseph L. Casale
Cheap? How about 50 bucks?

I have done this with home routers reflashed with OpenWRT running openvpn and 
if you can imagine, some have had literally year long uptimes...

jlc

From: Kennedy, Jim [kennedy...@elyriaschools.org]
Sent: Wednesday, April 11, 2012 1:26 PM
To: NT System Admin Issues
Subject: OTish VPN tunnel on the quick and cheap.

Need two simple cheap devices to fire up a point to point VPN tunnel. Cable 
modem at a small remote office back to a cable modem at the main office that we 
will tap into our primary network. Low traffic and very temporary. Suggestions?



~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Deploy MSI via SMS

2012-04-11 Thread Joseph L. Casale
GPO installations often pass the minimal required params to automate any setup 
for the obvious reason.
Load it in on a test GPO, and see what happens, often you need not do anything 
to get default behavior.

jlc

From: David Lum [david@nwea.org]
Sent: Wednesday, April 11, 2012 1:25 PM
To: NT System Admin Issues
Subject: Deploy MSI via SMS

Should be easy right? When I run the MSI directly, is asks for two questions: 
Accept the agreement, and user name/organization. How can I package it so 
running the MSI accepts defaults? Do I need to use something like ORCA (an MSI 
tool), or are there switches I’m too dumb to figure out they infer “use 
defaults”?
David Lum
Systems Engineer // NWEATM
Office 503.548.5229 // Cell (voice/text) 503.267.9764


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Powershell verbose pref

2012-04-11 Thread Joseph L. Casale
It was the moment I tried without it:)

Ugh, overlooked the obvious, I was convinced it had to be more difficult!

Thanks a ton for all the help on this Michael!
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Wednesday, April 11, 2012 3:18 PM
To: NT System Admin Issues
Subject: RE: Powershell verbose pref

And in case it isn’t clear, specifically what you will do is this:

$foo | ft -auto | out-string | write-verbose

From: Michael B. Smith [mailto:mich...@smithcons.com]
Sent: Wednesday, April 11, 2012 4:48 PM
To: NT System Admin Issues
Subject: RE: Powershell verbose pref

Use the pipeline, Luke.

$foo | Write-Verbose

That “unrolls” the object.

From: Joseph L. Casale 
[mailto:jcas...@activenetwerx.com]mailto:[mailto:jcas...@activenetwerx.com]
Sent: Wednesday, April 11, 2012 3:10 PM
To: NT System Admin Issues
Subject: RE: Powershell verbose pref

Yeah, problem is, the return that gets shoved into a variable appears to be an 
array of System.Object?
If I simply `$foo|ft -auto` I get a nice table, but I can't execute 
`Write-Verbose $foo` as a result of the System.Object type of its elements.
When I loop through element of the return, I am expecting a hash but I get 
system.management.automation.pscustomobject?

The output is the return of this function:

Function Get-StatementResult
{
Param
(
[System.Data.Odbc.OdbcConnection] $databaseHandle,
[String] $sql
)
$databaseCommand = New-Object System.Data.Odbc.OdbcCommand
$databaseCommand.Connection = $databaseHandle
$databaseCommand.CommandType = [System.Data.CommandType]::Text
$databaseCommand.CommandText = $sql
$reader = $databaseCommand.ExecuteReader()
$objectArray = @()
While ($reader.Read() -eq $True)
{
$hash = @{}
Foreach ($i in 0..($reader.FieldCount - 1))
{
$hash.$($reader.GetName($i)) = $reader.GetValue($i)
}
$objectArray += New-Object PSObject -property $hash
}
$databaseCommand.Cancel()
$databaseCommand = $null
Return $objectArray
}

Thanks!
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Wednesday, April 11, 2012 12:31 PM
To: NT System Admin Issues
Subject: RE: Powershell verbose pref
Have you taken a look at Write-Verbose ???

From: Joseph L. Casale 
[mailto:jcas...@activenetwerx.com]mailto:[mailto:jcas...@activenetwerx.com]
Sent: Wednesday, April 11, 2012 2:26 PM
To: NT System Admin Issues
Subject: Powershell verbose pref

I have a script where I simply piped a hash into a ft -auto to print it.
Now I am trying to only do this when the verbose flag is set and have all the 
lines prefixed with VERBOSE:.

Is there a simple way to do this, or must I test for verbose, then iterate 
through the hash?

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Creating objects within a function

2012-04-10 Thread Joseph L. Casale
Yeah,
I found an example working with databases that also got me headed in the right 
direction.

Thanks for the confirmation it was possible!

jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Tuesday, April 10, 2012 5:34 PM
To: NT System Admin Issues
Subject: RE: Creating objects within a function

Return it as the function value or as a [ref] value. Not sure I understand what 
you are asking for, if that isn’t what you mean…

function make-object()
{
$obj =  | select Company, Employee, Type, Rate, Balance, Date

return $obj
}

This returns a PSObject with the named fields. You can do the same thing with 
New-Object and Add-Member, but the v1 syntax shown above is MUCH faster.

From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Tuesday, April 10, 2012 7:20 PM
To: NT System Admin Issues
Subject: Creating objects within a function

How do you handle the case where you create .NET objects within a function and 
want to use them outside?
I have a block of code that I use in several places where I want to create a 
function for example.

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

Powershell arrays

2012-04-09 Thread Joseph L. Casale
If I want to write a script that takes a list of files as one of the inputs, is 
it safe to to define a
parameter as an array and pass it the files like c:\path\file,d:\path\file 
and expect the order
to be reliable?

is their a smarter way to do this, or is that sufficient?

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell arrays

2012-04-09 Thread Joseph L. Casale
Yup, just found it.

Thanks!
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Monday, April 09, 2012 9:56 AM
To: NT System Admin Issues
Subject: RE: Powershell arrays

That would be a type of System.Collections.Specialized.OrderedDictionary, by 
the way.

-Original Message-
From: Michael B. Smith [mailto:mich...@smithcons.com]
Sent: Monday, April 09, 2012 11:51 AM
To: NT System Admin Issues
Subject: RE: Powershell arrays

If you want an ordered dictionary, then you should specify an ordered 
dictionary. Otherwise, the order is defined to be random; even though may be 
able to determine a predictable order, it is not guaranteed. Especially between 
versions of PowerShell.

-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Monday, April 09, 2012 11:32 AM
To: NT System Admin Issues
Subject: Powershell arrays

If I want to write a script that takes a list of files as one of the inputs, is 
it safe to to define a parameter as an array and pass it the files like 
c:\path\file,d:\path\file and expect the order to be reliable?

is their a smarter way to do this, or is that sufficient?

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell parameters

2012-04-06 Thread Joseph L. Casale
Cool, I'll have a read on this one, ironically it looks better but is hardly 
simpler as you mention...

From: Michael B. Smith [mich...@smithcons.com]
Sent: Friday, April 06, 2012 10:50 AM
To: NT System Admin Issues
Subject: RE: Powershell parameters

You’ll have to use CmdletBinding and multiple parameter sets. It’s not “simple” 
(I would consider it “advanced PowerShell”) but it does what you want.

From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Friday, April 06, 2012 12:39 PM
To: NT System Admin Issues
Subject: Powershell parameters

Is there any shortcut to specify mandatory parameters that can be conditionaly 
ignored if a switch is present without a slew of following test case's and 
read-host code?

It would be nice to pull off something like:

param
(
If (!($Force)) { [Parameter(Mandatory = $True)] }
[string]$Path,
[Switch]$Force
)

Anything equally simple like this exist?

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Powershell SecureString parameters

2012-04-06 Thread Joseph L. Casale
Yeah, in the meantime for testing I am simply calling the script with a 
-Password $(ConvertTo-SecureString ... -AsPlainText -Force)

Ugly, but for testing its fine...

Thanks!
jlc

From: Steve Kradel [skra...@zetetic.net]
Sent: Friday, April 06, 2012 3:27 PM
To: NT System Admin Issues
Subject: Re: Powershell SecureString parameters

Feed in the characters to SecureString one at a time (string is an
IEnumerable of char)... the design reason for this is that the entire
string should not exist in managed memory at any point, or else there
will be non-secure copies floating around.

In practice, it is very difficult *not* to have the string in
cleartext unless you're prompting the user for char-level interactive
input, while being careful not to call any methods that would read
that input as a string.

I think MBS had a blog post about this specific to Powershell not too long ago.

--Steve

2012/4/6 Joseph L. Casale jcas...@activenetwerx.com:
 When you define a parameter as a secure string it becomes available like any
 cmdlet to specify during invocation not just after.

 In the scenarios like testing where security is not a concern, how do you
 craft the parameter such that it can take plaint text input and encrypt like
 `ConvertTo-SecureString some_pass -AsPlainText -Force`

 Thanks!
 jlc


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell error handling

2012-04-04 Thread Joseph L. Casale
Very insightful, thanks Michael!
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Wednesday, April 04, 2012 11:20 AM
To: NT System Admin Issues
Subject: RE: Powershell error handling

That’s because it returns a “decorated object” instead of just the name. Lots 
of PowerShell cmdlets do that. Even some that APPEAR to return simple text – 
don’t.

It doesn’t generate an error for the same reason that

$null.name_that_doesnt_exist

doesn’t return an error. :)

IIRC, it’s called “lazy member evaluation.” If you want the details, I can look 
them up.

If you WANT it to return an error, then

Set-StrictMode –Version 2.0

(I write scripts with StrictMode set. It can help find bugs. However, you have 
to verify that properties exist before you access them – which can make code 
look a little weird sometimes.)

Now – I don’t like the way you are doing that error detection. :)

If you track the performance of try/catch – it’s SLOW. Much much slower than 
what I recommend below:

$registryNameObject = Get-ItemProperty –Name “name” –Path 
“$RegPath\key” –EA 0
If( $? )
{
Write-host $registryNameObject.Name
}
Else
{
Write-Error $error[ 0 ].ToString()
}

Regards,
Michael B.

From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Wednesday, April 04, 2012 11:24 AM
To: NT System Admin Issues
Subject: Powershell error handling

Trying to wrap my head around the following case where you have a reg value you 
want to obtain.

Get-ItemProperty -Name name -Path $RegPath\key

To get that value into a variable:

(Get-ItemProperty -Name name -Path $RegPath\key -EA 1).name

If the value doesn't actually exists, you can trap that error in a try/catch.

For the sake of curiosity, why doesn't this generate an error:

(Get-ItemProperty -Name name -Path $RegPath\key -EA 
1).name_that_doesnt_exist

Its already odd enough you need extract it twice in the command...

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Powershell ODBC and SQL scripts

2012-04-04 Thread Joseph L. Casale
Hey guys,
I am hung up one last aspect (not being a devel :)...
The original scenario had sqlcmd invoked with the -I parameter for Quoted 
Identifiers.

I see this exists as a method for use here as well. The code I am using which 
is essentially what Steve outlined is partially:

$SqlCmd = New-Object System.Data.SqlClient.SqlCommand
$SqlCmd.CommandText = $SqlQuery
$SqlCmd.Connection = $SqlConnection

How exactly do I set that method?

Thanks guys,
jlc


From: Steve Kradel [skra...@zetetic.net]
Sent: Monday, April 02, 2012 11:49 AM
To: NT System Admin Issues
Subject: Re: Powershell ODBC and SQL scripts

What are your raw materials -- will you have one file with a bunch
of T-SQL for MSSQL, and a separate file with a bunch of PL/SQL for
Oracle?  Or are you trying to implement some logic in the code itself,
that will just work on various database platforms?

If the latter, this is a rather difficult problem.  Project like
NHibernate and FluentMigrations exist in this space... it is some
effort to learn how to use them, and they don't do everything anyway
(*especially* in the area of DDL / sprocs / etc.).

If the former, there are plenty of C# and VB.NET examples out there;
the general pattern is below... You should be able to adapt this to
Powershell with the [new-object] mumbo jumbo... this stuff is in the
System.Data.Common namespace:

/* 'factory' is the invariant name of a DbProviderFactory known to the
.NET runtime, registered either in app.config or machine.config */
var factory = DbProviderFactories.GetFactory(factory);
var conn = factory.CreateConnection();

/* 'cstr' is a database-specific connection string; something like
'Data Source=.;Initial Catalog=foo' for MSSQL */
conn.ConnectionString = cstr;
conn.Open();

/* now do stuff */
var cmd = conn.CreateCommand();
cmd.CommandText = select * from blar; // or pull commands from a file

--Steve
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: recommendations on home server

2012-04-03 Thread Joseph L. Casale
I have a few HP DL's which are not feasible, so I bought an ML150G6, quiet as 
hell, the downside is the ram is prohibitively expensive...

From: John Cook [john.c...@pfsf.org]
Sent: Tuesday, April 03, 2012 11:09 AM
To: NT System Admin Issues
Subject: RE: recommendations on home server

I have a 2950 at home (just as an example) and have never suffered any need to 
modify the electrical circuit. There are ways of isolating the noise but any 
fan is going to generate noise.  Irritates women – I’ll have to keep that handy 
in case I need to get rid of one!

 John W. Cook
Network Operations Manager
Partnership For Strong Families
5950 NW 1st Place
Gainesville, Fl 32607
Office (352) 244-1610
Cell (352) 215-6944
MCSE, MCP+I, MCTS, CompTIA A+, N+, VSP4, VTSP4

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Powershell question

2012-04-03 Thread Joseph L. Casale
Thanks guys!

From: Brian Desmond [br...@briandesmond.com]
Sent: Tuesday, April 03, 2012 4:13 PM
To: NT System Admin Issues
Subject: RE: Powershell question

How about something like this. You can figure out what $value1 and $value2 
should look like (could just be your Test-Path calls or maybe the function is 
registry aware...).

[bool]function XorValues($value1, $value2, [ref]$outputVal)
{
if ($value1 -xor $value2)
{
If ($value1)
{
$outputVal = $value1
return $true
}

If ($value2)
{
$outputVal = $value2
return $true
}
}
else
{
return $false
}
}

Thanks,
Brian Desmond
br...@briandesmond.com

w - 312.625.1438 | c   - 312.731.3132


-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Tuesday, April 03, 2012 4:27 PM
To: NT System Admin Issues
Subject: Powershell question

Hey guys,

What is the most elegant way to -xor test two paths and keep the one that 
exists?
I have a bunch of cases where I check for the existence of two reg keys (both 
can not co-exist) and then set a variable based on either one.

If ((Test-Path hklm:\... ) -xor (Test-Path hklm:\... )) {
 $var = value1 or value2
} Else {
 must exit the script
}

is the logic I need, but then I need additional code to set a single variable 
to value1 or value2.
Not a big deal once, but I have several and I was just hoping for a slick way 
to accomplish setting $var to either value based on which side tests true w/o 
another if block.

Thanks,
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin




~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



Powershell ODBC and SQL scripts

2012-04-02 Thread Joseph L. Casale
I have to make a ps script that is portable for use with MSSQL and Oracle 
backends to apply regular
schema updates then reload stored procs.

Starting with SQL half first, there is plenty of sample code for running 
individual statements against
an SQL server but that means rewriting the script each time. Anyone know a ps 
method using the
DbCommand Class to play a script into the database?

Thanks!
jlc



~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell ODBC and SQL scripts

2012-04-02 Thread Joseph L. Casale
What are your raw materials -- will you have one file with a bunch
of T-SQL for MSSQL, and a separate file with a bunch of PL/SQL for
Oracle?  Or are you trying to implement some logic in the code itself,
that will just work on various database platforms?

I'll know by means of some reg lookups I am doing up front. The sql
script will be handed down from the devel guys expecting the right db
so this part is trivial.

If the latter, this is a rather difficult problem.  Project like
NHibernate and FluentMigrations exist in this space... it is some
effort to learn how to use them, and they don't do everything anyway
(*especially* in the area of DDL / sprocs / etc.).

If the former, there are plenty of C# and VB.NET examples out there;
the general pattern is below... You should be able to adapt this to
Powershell with the [new-object] mumbo jumbo... this stuff is in the
System.Data.Common namespace:

Yup, after finding Michaels blog post almost immediately, I got that far.

/* 'factory' is the invariant name of a DbProviderFactory known to the
.NET runtime, registered either in app.config or machine.config */
var factory = DbProviderFactories.GetFactory(factory);
var conn = factory.CreateConnection();

/* 'cstr' is a database-specific connection string; something like
'Data Source=.;Initial Catalog=foo' for MSSQL */
conn.ConnectionString = cstr;
conn.Open();

/* now do stuff */
var cmd = conn.CreateCommand();
cmd.CommandText = select * from blar; // or pull commands from a file

And thats the part that I am still working on, I was hoping not to iterate 
through
the cmds in a file as there is a bunch of GO statements etc. I am hoping to
execute the file as a whole script.

Thanks guys!
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: recommendations on home server

2012-04-02 Thread Joseph L. Casale
Not to be the bearer of bad news, but raid/lots of power/low wattage and for 
500 to 1000?
I'd say not a chance.

Any decent raid card (by decent I mean has a BBWC) will easily be in the 
1000.00 range alone.

In my opinion most setups I see are disc io bound, so if you can put money in 
mostly one place, thats where.


From: Jimmy Tran [jt...@teachtci.com]
Sent: Monday, April 02, 2012 4:19 PM
To: NT System Admin Issues
Subject: recommendations on home server

I’m in need of a decent home server to run ESX-I to run SBS, W7 and some other 
test VM’s.  My budget is preferably around $500-$1k.  Looking for lots of 
processing power but low powered (if possible), RAID on the drives, decent 
amount of ram.  Don’t know where to start….can someone recommend something?

Jimmy


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: recommendations on home server

2012-04-02 Thread Joseph L. Casale
Trying to run more than 3-4 r2 hosts with something like Exchange on all of 
them over 1 spindle is like auto racing Yugos.
Sure, you can do it, but it doesn't impress anyone and it's not very fun to 
watch.


From: Richard Stovall [rich...@gmail.com]
Sent: Monday, April 02, 2012 5:15 PM
To: NT System Admin Issues
Subject: Re: recommendations on home server

Funny.  For what I presume his purposes are (home lab, learning, testing, 
etc.), I would recommend a bunch of RAM and to not worry too much about disk 
I/O, RAID or CPU power.  A regular PC with 12GB or 16GB RAM, an i5 or i7 CPU, 
and a decent SATA hard drive ought to do nicely for mucking about with the new 
toys from Microsoft.

Also, why limit yourself to ESXi.  Hyper-V server is free and works great on a 
large variety of hardware.

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Hyjack - Linux in the Enterprise/Schools (was RE: Sophisticated Phising attempt?)

2012-03-29 Thread Joseph L. Casale
 There are still some fairly basic hurdles that Linux needs to get over in 
 order to make it in Enterprise/Schools:

 1. Centralized management improvements: My boss wants everything to be 
 point-and-click, so no CLI options would work here.

This statement negates the first?  Automate, but you want shinny clicky stuff? 
Frankly, in with windows
if it doesn't have a cli alternative, I discount it. It only does excel in 
Enterprise for these reasons where in
reality what your boss wants is what doesn't.

 If it can't be done in a GUI, she won't go for it... because what if I leave 
 and nobody else knows how to fix things?

No comment... So what she wants is not to learn a technology, but to see a gui 
that points her along so
she just has to click next, next, next and not know what she's doing? Wow...

 And how do you deploy a printer to a lab? What about updating Firefox in an 
 entire school?

Trivial in linux. By design even... Updates are something still not as perfect 
in Windows as it is in Linux.
From initial deployment even, I've written kickstarts that not only deployed 
the machine but setup every
running daemon and configured it 100% that I didn't need to back those servers 
up, if they failed I redeployed
in mere minutes. Given all the configuration management tools that exist, the 
options here limitless.

 Thus far, Webmin might be the best current solution to this problem, but I 
 can't webmin 20 computers
 at the same time as far as I know.

Honestly bud, no real Linux admin uses webmin, and for what its worth, I have 
never even setup a Linux
server with a gui, oh I worked on one in a rhel class once:)

 2. Network home folders: Everybody loves that their documents are 
 automatically saved to the server...
 and we like not having to backup 1000+ desktops. Getting this to work in 
 Linux is no cakewalk.

It is actually, you simply don't how. Automount to name one of several ways 
that come to mind?

I am fine that you don't like Linux, thats cool, but your statements are all 
factually incorrect.
If you just say Linux sucks because you don't like it, thats valid and i can 
dig it. However it excels
in all the areas you point out in reality.

jlc



~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: BB curve 9300 installation

2012-03-27 Thread Joseph L. Casale
Not so sure thats right, the device is unknown and wont charge, from what I 
have read and experience with other devices, it will need a driver.
I just didn't want to install any more than I had...
I suppose I could unpack that msi, but probably more work than its worth.

jlc

From: Jeff Brown [jbr...@webcoindustries.com]
Sent: Tuesday, March 27, 2012 1:52 PM
To: NT System Admin Issues
Subject: RE: BB curve 9300 installation

No need to install software to charge.  Desktop manager is needed to 
sync/update software if not connected to a BES.

From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Tuesday, March 27, 2012 2:33 PM
To: NT System Admin Issues
Subject: BB curve 9300 installation

We don't use bb's here, but a salesman has asked me to install the driver so it 
can be charged on his laptop.
Is it just BlackBerry Device Manager I need for this guy?

Thanks,
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

This email and any attachments transmitted with it are confidential and 
intended solely for the use of the addressee. If you have received this email 
in error please notify the sender immediately. All inquiries, quotations, 
purchase orders, acknowledgments, invoices or other documents memorializing 
offers, acceptances or contractual obligations are subject to Webco’s standard 
terms and conditions of sale (when Webco is the seller, 
www.webcoindustries.com/tcsales.aspx) or purchase (when Webco is the buyer, 
www.webcoindustries.com/tcpurchase.aspx). Webco manufactures tubular products 
to meet customer dimensional and materials specifications. Webco is not an 
engineering or design business. Any engineering information provided is purely 
incidental to the tube manufacturing process and not offered or intended to be 
engineering services related to the performance specifications a customer may 
require, which is the customer’s responsibility to determine.

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: BB curve 9300 installation

2012-03-27 Thread Joseph L. Casale
When I asked him to confirm it came out he had not actually tried:)
Sorry guys,
jlc

From: Steve Hanna [sha...@fleet.ca]
Sent: Tuesday, March 27, 2012 3:09 PM
To: NT System Admin Issues
Subject: Re: BB curve 9300 installation

I carry the phone you mention. USB and plug it in to what ever is closest.

--steve
Sent with BlackBerry

From: Joseph L. Casale jcas...@activenetwerx.com
Date: Tue, 27 Mar 2012 20:30:14 +
To: NT System Admin Issuesntsysadmin@lyris.sunbelt-software.com
ReplyTo: NT System Admin Issues ntsysadmin@lyris.sunbelt-software.com
Subject: RE: BB curve 9300 installation

Not so sure thats right, the device is unknown and wont charge, from what I 
have read and experience with other devices, it will need a driver.
I just didn't want to install any more than I had...
I suppose I could unpack that msi, but probably more work than its worth.

jlc

From: Jeff Brown [jbr...@webcoindustries.com]
Sent: Tuesday, March 27, 2012 1:52 PM
To: NT System Admin Issues
Subject: RE: BB curve 9300 installation

No need to install software to charge.  Desktop manager is needed to 
sync/update software if not connected to a BES.

From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Tuesday, March 27, 2012 2:33 PM
To: NT System Admin Issues
Subject: BB curve 9300 installation

We don't use bb's here, but a salesman has asked me to install the driver so it 
can be charged on his laptop.
Is it just BlackBerry Device Manager I need for this guy?

Thanks,
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

This email and any attachments transmitted with it are confidential and 
intended solely for the use of the addressee. If you have received this email 
in error please notify the sender immediately. All inquiries, quotations, 
purchase orders, acknowledgments, invoices or other documents memorializing 
offers, acceptances or contractual obligations are subject to Webco’s standard 
terms and conditions of sale (when Webco is the seller, 
www.webcoindustries.com/tcsales.aspx) or purchase (when Webco is the buyer, 
www.webcoindustries.com/tcpurchase.aspx). Webco manufactures tubular products 
to meet customer dimensional and materials specifications. Webco is not an 
engineering or design business. Any engineering information provided is purely 
incidental to the tube manufacturing process and not offered or intended to be 
engineering services related to the performance specifications a customer may 
require, which is the customer’s responsibility to determine.

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

Powershell reg binary issue

2012-03-26 Thread Joseph L. Casale
I am trying to save the result of a Reg Binary value from one key into the 
value of another key, any idea
on how to save the output of get-itemproperty or pipe it into set-itemproperty 
for use with reg binary values?

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell reg binary issue

2012-03-26 Thread Joseph L. Casale
There is a type mismatch, or its getting cast to a string as a result of the 
way i incorrectly call it:

$path=Registry::HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet
 Settings\Connections
$path2=Registry::HKEY_USERS\.DEFAULT\Software\Microsoft\Windows\CurrentVersion\Internet
 Settings\Connections

$foo=Get-ItemProperty -Path $path -Name DefaultConnectionSettings
Set-ItemProperty -Path $path2 -Name DefaultConnectionSettings -Value $foo

See what I am doing wrong?
jlc

From: Brian Desmond [br...@briandesmond.com]
Sent: Monday, March 26, 2012 6:40 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

You could just put it in $foo or some variable. No need to dump it to a temp 
file.

Thanks,
Brian Desmond
br...@briandesmond.com

w - 312.625.1438 | c   - 312.731.3132


-Original Message-
From: Michael B. Smith [mailto:mich...@smithcons.com]
Sent: Monday, March 26, 2012 7:16 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

Out-file -encoding binary

Or similar.

-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Monday, March 26, 2012 8:01 PM
To: NT System Admin Issues
Subject: Powershell reg binary issue

I am trying to save the result of a Reg Binary value from one key into the 
value of another key, any idea on how to save the output of get-itemproperty or 
pipe it into set-itemproperty for use with reg binary values?

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin




~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell reg binary issue

2012-03-26 Thread Joseph L. Casale
Believe it or not, that was my very first attempt (hence the pipe inquiry in 
first email) but it errors out:

Set-ItemProperty : The input object cannot be bound to any parameters for the 
command either because the command does not take pipeline input or the input 
and its properties do not
 match any of the parameters that take pipeline input.

From: Michael B. Smith [mich...@smithcons.com]
Sent: Monday, March 26, 2012 7:07 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

What has $foo got to do with anything?

This is all you need based on what you've said so far:

Get-ItemProperty -Path $path -Name DefaultConnectionSettings | 
Set-ItemProperty -Path $path2 -Name DefaultConnectionSettings

-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Monday, March 26, 2012 8:56 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

There is a type mismatch, or its getting cast to a string as a result of the 
way i incorrectly call it:

$path=Registry::HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet
 Settings\Connections
$path2=Registry::HKEY_USERS\.DEFAULT\Software\Microsoft\Windows\CurrentVersion\Internet
 Settings\Connections

$foo = Get-ItemProperty -Path $path -Name DefaultConnectionSettings 
Set-ItemProperty -Path $path2 -Name DefaultConnectionSettings -Value $foo

See what I am doing wrong?
jlc

From: Brian Desmond [br...@briandesmond.com]
Sent: Monday, March 26, 2012 6:40 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

You could just put it in $foo or some variable. No need to dump it to a temp 
file.

Thanks,
Brian Desmond
br...@briandesmond.com

w - 312.625.1438 | c   - 312.731.3132


-Original Message-
From: Michael B. Smith [mailto:mich...@smithcons.com]
Sent: Monday, March 26, 2012 7:16 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

Out-file -encoding binary

Or similar.

-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Monday, March 26, 2012 8:01 PM
To: NT System Admin Issues
Subject: Powershell reg binary issue

I am trying to save the result of a Reg Binary value from one key into the 
value of another key, any idea on how to save the output of get-itemproperty or 
pipe it into set-itemproperty for use with reg binary values?

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin




~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Powershell reg binary issue

2012-03-26 Thread Joseph L. Casale
Lol, both this and Ken's worked.

I did have to specify type binary as the default was a string here.

Thanks guys!
jlc

From: Michael B. Smith [mich...@smithcons.com]
Sent: Monday, March 26, 2012 7:38 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

Stupid registry provider is just stupid.

Get-ItemProperty -Path $path -Name DefaultConnectionSettings |% { 
Set-ItemProperty -Path $path2 -Name DefaultConnectionSettings -Value $_. 
DefaultConnectionSettings }

-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Monday, March 26, 2012 9:17 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

Believe it or not, that was my very first attempt (hence the pipe inquiry in 
first email) but it errors out:

Set-ItemProperty : The input object cannot be bound to any parameters for the 
command either because the command does not take pipeline input or the input 
and its properties do not  match any of the parameters that take pipeline input.

From: Michael B. Smith [mich...@smithcons.com]
Sent: Monday, March 26, 2012 7:07 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

What has $foo got to do with anything?

This is all you need based on what you've said so far:

Get-ItemProperty -Path $path -Name DefaultConnectionSettings | 
Set-ItemProperty -Path $path2 -Name DefaultConnectionSettings

-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Monday, March 26, 2012 8:56 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

There is a type mismatch, or its getting cast to a string as a result of the 
way i incorrectly call it:

$path=Registry::HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet
 Settings\Connections
$path2=Registry::HKEY_USERS\.DEFAULT\Software\Microsoft\Windows\CurrentVersion\Internet
 Settings\Connections

$foo = Get-ItemProperty -Path $path -Name DefaultConnectionSettings 
Set-ItemProperty -Path $path2 -Name DefaultConnectionSettings -Value $foo

See what I am doing wrong?
jlc

From: Brian Desmond [br...@briandesmond.com]
Sent: Monday, March 26, 2012 6:40 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

You could just put it in $foo or some variable. No need to dump it to a temp 
file.

Thanks,
Brian Desmond
br...@briandesmond.com

w - 312.625.1438 | c   - 312.731.3132


-Original Message-
From: Michael B. Smith [mailto:mich...@smithcons.com]
Sent: Monday, March 26, 2012 7:16 PM
To: NT System Admin Issues
Subject: RE: Powershell reg binary issue

Out-file -encoding binary

Or similar.

-Original Message-
From: Joseph L. Casale [mailto:jcas...@activenetwerx.com]
Sent: Monday, March 26, 2012 8:01 PM
To: NT System Admin Issues
Subject: Powershell reg binary issue

I am trying to save the result of a Reg Binary value from one key into the 
value of another key, any idea on how to save the output of get-itemproperty or 
pipe it into set-itemproperty for use with reg binary values?

Thanks!
jlc

~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin




~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin


~ Finally, powerful endpoint security that ISN'T a resource hog! ~ ~ 
http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http

Re: Win 2008 Restore glitch with Windowsimagebackup

2012-03-23 Thread Joseph L. Casale
Drvload gets drivers in at the winpe stage.

jlc

On Mar 23, 2012, at 12:03 AM, Jay Kulsh jayku...@csi.com wrote:

 This Win 2008 server totally crashed and I have Windowsimagebackup  
 of all critical volumes on a remote server.

 Did not have large enough portable USB disk to copy that backup and  
 connect to crashed server, and could not view network while using  
 Restore option with OS DVD.

 So, did a quick install of OS and after network could be seen, used  
 remote location to restore the backup image. However, since C: drive  
 was in use, the restored image could only be put on D: drive. Made  
 D: partition active and C: inactive, and now none are working.

 My question: If I do the temp OS install on D: drive and then do a  
 restore to C: drive from that network location, will I be able to  
 get back the old server if I make C: active and D: inactive? Thanks.

 Jay Kulsh
 So. Pasadena, CA
 ~ Finally, powerful endpoint security that ISN'T a resource hog! ~
 ~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

 ---
 To manage subscriptions click here: 
 http://lyris.sunbelt-software.com/read/my_forums/
 or send an email to listmana...@lyris.sunbeltsoftware.com
 with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: Exch 2010 - Msg Size Limit - Unexplained

2012-03-16 Thread Joseph L. Casale
Have you enabled logging and sent a message to see where/why it failed?

From: Mark Boeck [netadmin...@gmail.com]
Sent: Friday, March 16, 2012 7:15 AM
To: NT System Admin Issues
Subject: Exch 2010 - Msg Size Limit - Unexplained

Greets!

I'm running MS Exch 2010 SP2.  I cannot receive messages ~ 12 - 15MB.

Postini filters my inbound mail - it is set to 200MB

Org Config --- Hub Transport --- Global Settings (tab) --- Transport 
Settings --- Max send/receive both set to 20240 KB

The user mailbox has no size limit settings - it accepts those defaults.

Ideas greatly appreciated!
Happy Friday!

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to 
listmana...@lyris.sunbeltsoftware.commailto:listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin

RE: Re: Windows File Archive

2012-03-09 Thread Joseph L. Casale

I rarely talk that way (and I have to be really angry or really drunk) and I 
just don’t like it.
 
Dude, you are like a pillar of knowledge to me, no matter how busy I am, I read 
at least
your posts.

The thought of you drunk A) Is hilarious, and B) Humanizes you from that pillar 
I have you on.

Awesome...
jlc
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: FTP site configuration backups

2012-03-08 Thread Joseph L. Casale
So you know the passwords, you know the config, you set the perms, so why not 
simply
keep a powershell script of all the account creation etc updated. It sounds 
like like its fairly
repetitive and you could simply loop through all the user/directory creation, 
apply acl's etc from
the list of users.

Server breaks, you redeploy and execute a continuously updated script. 
Powershell has
some IIS extensions (although I have never done explicit ftp work with it)...

I really don't see it needing to be more complex than this?


From: Kurt Buff [kurt.b...@gmail.com]
Sent: Thursday, March 08, 2012 2:12 PM
To: NT System Admin Issues
Subject: Re: FTP site configuration backups

I believe I have a slightly different situation than what you're
describing, but I could be wrong, so correct me if I am.

On this server, the FTP users are accounts in the local accounts base
- we chose to do that so that vendors/partners would each have a
protected directory with exclusive access to it. That would place the
names and accounts in the SAM database, correct?

Regardless, this would require poking holes in the firewall that
aren't already there, which I'm reluctant to do.

Thanks,

Kurt
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



RE: FTP site configuration backups

2012-03-08 Thread Joseph L. Casale
That's a good theory, and indeed part of the solution, but in
practice, people are fallible, and will fail to keep the script
updated.

While I appreciate that, invariably that line of thinking can be
applied to even your own design as someone will always find
a way to fsck up anything, lol. You make a script, ok, so does
some passive monitoring solution inform you when the script
isn't run: your firewall guy changed something so you didn't get
updates etc...

You gotta have some faith:)...
~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to listmana...@lyris.sunbeltsoftware.com
with the body: unsubscribe ntsysadmin



  1   2   3   4   5   6   7   8   9   10   >