<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Wmi on BAFM</title><link>https://christian.blog.pakiheim.de/tags/wmi/</link><description>Recent content in Wmi on BAFM</description><generator>Hugo -- 0.160.1</generator><language>en</language><lastBuildDate>Sat, 16 Aug 2014 10:15:10 +0000</lastBuildDate><atom:link href="https://christian.blog.pakiheim.de/tags/wmi/index.xml" rel="self" type="application/rss+xml"/><item><title>VBscript undamp; Active Directory and printers</title><link>https://christian.blog.pakiheim.de/posts/2014-08-16_vbscript-amp-active-directory-and-printers/</link><pubDate>Sat, 16 Aug 2014 10:15:10 +0000</pubDate><guid isPermaLink="false">http://blog.barfoo.org/2007/10/13/vbscript-active-directory/</guid><description>&lt;p&gt;Well, since our current solution for mapping printers is an ugly batch file, which needs to be put into &lt;em&gt;Startup&lt;/em&gt;, I today poked at doing it in VBscript (I know, but it&amp;rsquo;s less ugly than the batch script, trust me).&lt;/p&gt;
&lt;p&gt;As some of you know, printers are only applicable to users (as in you can&amp;rsquo;t put a startup script onto an OU, which is going to map the printers). So as we store users and the computes in different OU&amp;rsquo;s in our Active Directory (we do have about 15.000 students), I can&amp;rsquo;t apply the printer.vbs to the users OU directly either, unless I implement some intelligence into the script itself.&lt;/p&gt;</description></item><item><title>VBscript: Query remote OS and SP info</title><link>https://christian.blog.pakiheim.de/posts/2014-08-08_vbscript-query-remote-os-and-sp-info/</link><pubDate>Fri, 08 Aug 2014 08:34:49 +0000</pubDate><guid isPermaLink="false">http://blog.barfoo.org/?p=2953</guid><description>&lt;p&gt;As I wrote &lt;a href="https://christian.blog.pakiheim.de/posts/2014-08-08_windows-server-2003-sp1-wsus-and-security-updates" title="Windows Server 2003 SP1, WSUS and Security Updates"&gt;on Thursday&lt;/a&gt;, I am battling with Windows Server 2003. Now I got a list out of our change management database, which sadly ain&amp;rsquo;t that accurate. So in order to get reliable information about the target systems (in order to do some accurate planning), I ended up writing a small vbscript which simply takes the hostname on the command line (cscript //NoLogo win_sp_level.vbs 10.0.0.5) and returns a csv-like element.&lt;/p&gt;</description></item><item><title>Displaying Windows Architecture with bginfo</title><link>https://christian.blog.pakiheim.de/posts/2010-06-18_displaying-windows-architecture-with-bginfo/</link><pubDate>Fri, 18 Jun 2010 15:22:08 +0000</pubDate><guid isPermaLink="false">http://blog.barfoo.org/?p=3111</guid><description>&lt;p&gt;On all our servers in the basement, we do have &lt;a href="http://technet.microsoft.com/de-de/sysinternals/bb897557.aspx"&gt;bginfo&lt;/a&gt; installed, in order to quickly get certain information. Now as I was struggling with a big Service Pack roll out, I looked into making bginfo also display the OS architecture. But apparently it isn&amp;rsquo;t that easy &amp;hellip; At least bginfo doesn&amp;rsquo;t provide it by default.&lt;/p&gt;
&lt;p&gt;After (yet another hour in front of Google), I finally found what I was &lt;a href="http://stackoverflow.com/questions/1413409/how-to-determine-os-platform-with-wmi"&gt;looking for&lt;/a&gt;. At first I didn&amp;rsquo;t limit the query on a specific CPU, but that turned out to be shitty (x32 being displayed twice, once for each CPU). But after limiting it to DeviceID=&amp;lsquo;CPU0&amp;rsquo; it works like a charm &amp;#x1f609;&lt;/p&gt;</description></item><item><title>VBscript: Query remote OS and SP info (continued)</title><link>https://christian.blog.pakiheim.de/posts/2010-02-15_vbscript-query-remote-os-and-sp-info-continued/</link><pubDate>Mon, 15 Feb 2010 20:34:34 +0000</pubDate><guid isPermaLink="false">http://blog.barfoo.org/?p=2975</guid><description>&lt;p&gt;After some more crunching on &lt;a href="https://christian.blog.pakiheim.de/posts/2010-02-15_vbscript-query-remote-os-and-sp-info-continued" title="VBscript: Query remote OS and SP info"&gt;my VBscript&lt;/a&gt;, I think I finally have a working script that runs through a csv-list I point it to and walk onto each system (by ip-address only sadly) and query the os and the Service Pack that is installed. The CSV may look like this:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;div class="chroma"&gt;
&lt;table class="lntable"&gt;&lt;tr&gt;&lt;td class="lntd"&gt;
&lt;pre tabindex="0" class="chroma"&gt;&lt;code&gt;&lt;span class="lnt" id="hl-0-1"&gt;&lt;a class="lnlinks" href="#hl-0-1"&gt;1&lt;/a&gt;
&lt;/span&gt;&lt;span class="lnt" id="hl-0-2"&gt;&lt;a class="lnlinks" href="#hl-0-2"&gt;2&lt;/a&gt;
&lt;/span&gt;&lt;span class="lnt" id="hl-0-3"&gt;&lt;a class="lnlinks" href="#hl-0-3"&gt;3&lt;/a&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;
&lt;td class="lntd"&gt;
&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-fallback" data-lang="fallback"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;Hostname;IP;Model;Description;OS;Service-Pack;BL;Priority
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;epimetheus;10.0.0.2;VMware guest;File-Server
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;hades;10.0.0.1;VMware guest;Core-Router
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;
&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;After saving that one, and running a cscript //NoLogo win_sp_level.vbs you should find a completed list like this:&lt;/p&gt;</description></item><item><title>VBscript undamp; Active Directory and printers (continued)</title><link>https://christian.blog.pakiheim.de/posts/2008-12-05_vbscript-amp-active-directory-and-printers-continued/</link><pubDate>Fri, 05 Dec 2008 21:54:09 +0000</pubDate><guid isPermaLink="false">http://blog.barfoo.org/index.php/2007/10/25/vbscript-active-directory-and-printers-continued/</guid><description>&lt;p&gt;As I &lt;a href="https://christian.blog.pakiheim.de/posts/2008-12-05_vbscript-amp-active-directory-and-printers-continued" title="VBscript &amp;amp; Active Directory and printers ?"&gt;posted earlier&lt;/a&gt;, I tried working around some limitations in Microsoft&amp;rsquo;s Active Directory by teaching the script some intelligence.&lt;/p&gt;
&lt;p&gt;But, since we recently started using Thin Clients, all the stuff I did with the fancy vbs was just a waste-of-time. Turns out, Windows XP Embedded doesn&amp;rsquo;t work quite the same as a &amp;quot; &lt;em&gt;normal&lt;/em&gt;&amp;quot; Windows XP (that&amp;rsquo;s where I tested the script on), and it simply dies when running the WMI Query. Bollocks.&lt;/p&gt;</description></item></channel></rss>