Get-WMI object exporting IP configuration to HTML only displays System.String[]

Hi,
 I'm trying to customise a powershell script I found in the technet gallery for server inventory by adding reporting information for IP details. The disk sample works perfectly and I can export my data to an HTML file, but the IP address information
I'm struggling with.
The IP information displays:
True
System.String[]
System.String[]
System.String[]
laptop-04
00:DB:DF:0D:84:
I can use the IP powershell ina for loop and display the IP details correctly, but in this format if I want to export it to a HTML it doesn't work, please advise.
$IPInfo = Get-WmiObject -Class Win32_NetworkAdapterConfiguration -Filter IPEnabled=TRUE -ComputerName $ComputerName | Select-Object -Property [a-z]* -ExcludeProperty IPX*,WINS* |
select DHCPEnabled, IPAddress, IPSubnet, DefaultIPGateway, DNSHostName, MACAddress | ConvertTo-Html -Fragment 
#Logical Disk Information
#the @Name below simply renames the size
$Disk = Get-WmiObject -Class Win32_LogicalDisk -Filter DriveType=3 | 
Select SystemName , DeviceID , @{Name=”size(GB)”;Expression={“{0:N1}” -f($_.size/1gb)}}, @{Name=”freespace(GB)”;Expression={“{0:N1}” -f($_.freespace/1gb)}} |
ConvertTo-Html -Fragment
Thanks in advance...
IT Support/Everything

jrv,
 Many thanks, much appreciated :-)
I've used your format to get the following:
$IPInfo = Get-WmiObject -Class Win32_NetworkAdapterConfiguration -Filter IPEnabled=TRUE -ComputerName $ComputerName | Select-Object -Property [a-z]* -ExcludeProperty IPX*,WINS* |
select DHCPEnabled, @{N='IPAddress';E={$_.IPAddress -join '|'}}, @{N='IP Subnet';E={$_.IPSubnet -join '|'}}, @{N='Default IP Gateway';E={$_.DefaultIPGateway -join '|'}}, DNSHostName, MACAddress | ConvertTo-Html -Fragment 
QQ - I get the @{N='IPAddress' is used to rename the IP Address, but does the 'E={$_.IPAddress -join '|'}}' do? I can guess it's an express to expand the $_.IPAddress and pipe all the results into a join, but I'm not sure as I've never seen the 'E=' format
before.
@{N='IPAddress';E={$_.IPAddress -join '|'}}
Thanks again

Similar Messages

  • Get-WMI Object (0x800706F7) - The stub received bad data

    Hello there,
    i have an problem related to the above error..
    When i do a remote wmi call and pass the credentials like this (from an script)
    $passS =[ServerEye.PowerShellAPI]::Decrypt($pass)
    $securePass = convertto-securestring $passS -asplaintext -force
    $credential = New-Object System.Management.Automation.PsCredential("$domain\$user",$securePass)
    $buffer = gwmi -Query "select * from Win32_PerfFormattedData_MSExchangeRpcClientAccess_MSExchangeRpcClientAccess" -Credential $credential -Authentication Default -ComputerName $computer -ErrorAction Stop
    i sometimes get the above error with the stub received bad data...
    When i open a new powershell and do the wmi request it works.. When i close the powershell.exe and execute the above code again from the same script it works. But sometimes (totally) random this issue occurs for the existing powershell.exe process and will
    never go away till i close the process (which is not option, since i am using a deamon which runs script from a queue folder.. and this deamon runs for a long time.. 
    When i restart the server.. this issue never occurs for a long time but then suddenly reoccurs. 
    Anyone has an idea? I found one similar thread, but in this the solution was to pass the credential data in a server\user format or an domain\user format, which i am doing
    Is this a bug? Is this an scripting flaw from my side? What can i do against it... Any help would be really cool!!

    Thank you in advance for your answer. This is somehow what i expected..
    Sadly those are not our own servers. They are from a customer that is using our script to monitor several aspects.. and of course the software is always to blame :D (From a customer perspective).
    But i will inform the customer because this connection issue could be absolutly possible since i also see powershell sessions that get broken due to server communication..
    The only thing i really do not understand is, why it does not "repair" itselfs. What is the difference between closing the powershell.exe or simply re-executing the same get-wmiobject request..  I dont know how get-wmiobject manages its connection..
    but shouldn it do a new connection to the remote-server for each call?

  • How to get BW Objects not optmized for HANA on just migrated System from ORA to HANA?

    http://www.saphana.com/servlet/JiveServlet/previewBody/1363-102-2-1810/SDN_HANA_opt_InfoCube%20FINAL.PDF
    HI  .....HANA Experts
    We are early birds for HANA Technology !!!
    The above link is showing how to convert and limitations etc.
    We just migrated BW from Oracle to HANA.
    Our experts converted some BW Obejcts to HANA Optimized , some still open.
    Q1) In this juncture, to take the current stcok, Do we have any report which extract  directly list of BW objects which are still not optimized for HANA.
    Q2) How to get list of tables not yet fully loaded into Memory [or] How to get list of Infocubes & DSO's not yet fully loaded into main memeory
    Q3) When we optimize objects - The size in memeory & persistance store - Size is increasing - Is it normal behaviour ?
    Rgds
    PR
    PR Srinivas

    Hi,
    PR Srinivas wrote:
    We just migrated BW from Oracle to HANA.
    Our experts converted some BW Obejcts to HANA Optimized , some still open.
    ---- DSOs should not be converted. If you still want to please check RSODSO Table and check the column IMOFL (HANA Optimized setting for the DSO).
    For the InfoCubes, please refer to RSDCUBE table and CUBESUBTYPE column with value F for HANA optimized setting.
    Q1) In this juncture, to take the current stcok, Do we have any report which extract  directly list of BW objects which are still not optimized for HANA.
    Q2) How to get list of tables not yet fully loaded into Memory [or] How to get list of Infocubes & DSO's not yet fully loaded into main memeory
    Please check m_cs_tables to know which tables are loaded to memory and which are not.(Refer to LOADED column).
    Q3) When we optimize objects - The size in memeory & persistance store - Size is increasing - Is it normal behaviour ?
    Please check the Delta memory and perform Delta Merge. Please search on SCN to get the details on the same.
    Rgds
    PR
    PR Srinivas

  • Get a reference to a table which is only known as string

    Hi all,
    is there a way to get the real variable from a String?
    The coding is like this:
    Data: itab1 type table of XXX,
            itab2 type table of XXX,
            itab3 type table of XXX,
    Somewhere in the program i read a configuration table and get for example the string 'itab2'.
    Is there a way to get from the string 'itab2' to the real itab2?
    Because I'm in a User-Exit in a generated program, I don't know which tables are defined. If the name is in the configuration table, the real table is existing.
    Best regards
    Dominik

    Pl find the below code.
      DATA: lv_tab_name TYPE dd02l-tabname.
      FIELD-SYMBOLS: <fs_inttab> TYPE STANDARD TABLE.
      DATA : lr_tab  TYPE REF TO data.
        CREATE DATA lr_tab TYPE STANDARD TABLE OF (lv_tab_name).
        ASSIGN lr_tab->* TO <fs_inttab>.
          SELECT * FROM (lv_tab_name)
                   INTO TABLE <fs_inttab>
                   WHERE (lv_where).
    Hope it helps.
    Thanks,
    Srinivas

  • Export OSB configuration from eclipse using ant script

    I am trying to export an OSB project from eclipse using ant script
    I followed the link below http://biemond.blogspot.com/2010/07/osb-11g-ant-deployment-scripts.html
    It is using com.bea.alsb.core.ConfigExport to do the export. This export is always set to resource level.
    I see it generates a file ExportInfo setting some properties. It has a property that set the export level as below
    <imp:property name="projectLevelExport" value="false"/>*
    How can I export the project in project level? basically setting projectLevelExport to true?
    So that if a file does not exist in the sbconfig.jar file , then while importing the jar to OSB server it will delete the file from the server instead of skipping it?
    I appreciate any help
    here is the ant script snippet that gets executed to export from eclipse
    <target name="exportFromWorkspace">
         <delete failonerror="false" includeemptydirs="true"
    dir="${metadata.dir}"/>     
                   <!--eclipse.refreshLocal resource="${config.project}" depth="infinite"/-->
    <java dir="${eclipse.home}"
    jar="${eclipse.home}/plugins/org.eclipse.equinox.launcher_1.1.0.v20100507.jar"
    fork="true" failonerror="true" maxmemory="768m">
    <jvmarg line="-XX:MaxPermSize=256m"/>
    <arg line="-data ${workspace.dir}"/>
    <arg line="-application com.bea.alsb.core.ConfigExport"/>
    <arg line="-configProject ${config.project}"/>
    <arg line="-configJar ${config.jar}"/>
    <arg line="-configSubProjects ${config.subprojects}"/>
              <arg line="-exportLevel true"/>
    <arg line="-includeDependencies ${config.includeDependencies}"/>
    <sysproperty key="weblogic.home" value="${weblogic.home}"/>
    <sysproperty key="osb.home" value="${osb.home}"/>
    <sysproperty key="osgi.bundlefile.limit" value="500"/>
    <sysproperty key="harvester.home" value="${osb.home}/harvester"/>
    <sysproperty key="osgi.nl" value="en_US"/>
    <sysproperty key="sun.lang.ClassLoader.allowArraySyntax" value="true"/>
    </java>
    </target>

    yes, I specified the project name to export the whole project.
    Here is few lines from my properties file
    # properties for workspace export
    config.project="OSB Configuration-GW"
    config.jar=D:/workspace/osb/scripts/gateway/mycode2/ant_osb/dist/sbconfig.jar
    config.subprojects="GatewaySecurity"
    config.includeDependencies=true
    workspace.dir=D:/workspace/osb/gateway-workspace
    But this property does not make it to export at project level ,it export the specified project at resource level.
    And while importing this jar to OSB server, if a file is missing it skips the file instead of deleting the file from the OSB server
    If I unjar sbconfig.jar file, open ExportInfo file and update the line in bold below to true then it deletes the file from OSB server, if not exist in sbconfig.jar
    <imp:property name="exporttime" value="Thu Dec 29 13:57:44 EST 2011"/>
    <imp:property name="productname" value="Oracle Service Bus"/>
    <imp:property name="productversion" value="11.1.1.4"/>
    *<imp:property name="projectLevelExport" value="false"/>*
    Here is few lines from Oracle API java doc
    http://docs.oracle.com/cd/E13171_01/alsb/docs26/javadoc/com/bea/wli/sb/management/importexport/ALSBImportOperation.Operation.html
    public static final ALSBImportOperation.Operation Delete
    Indicates that the resource is deleted in the importing domain. This is the default operation when the project is exported in its entirety and the resource exists in the target domain but not in the jar file
    public static final ALSBImportOperation.Operation Skip
    Indicates that the resource is skipped meaning the resource is not touched in the importing domain. This is the default operation if the jar file was exported at the resource level, and a resource that exists in the target domain, does not exist in the jar file.

  • Export portal configuration

    After setting up the portal using the Portal Admin Console, as you can export the configuration to another domain?

    YES, very much. There is something called Propagation Tool, to propagate all the Portal Resources (or whichever resources you want like using scoping approach) from one domain to another domain. Here is the link for that for WLP 10.3. Read all the limitations also. But it pretty much propagate everything and is very commonly used by many customers
    http://download.oracle.com/docs/cd/E13155_01/wlp/docs103/prodOps/PART-2.html
    Note: If you are on 8.1 SPxx, you need to get this propagation tool like a separate jar file. But in 9.x and 10.x, this tool is built in.
    Goud

  • Export Server Configuration - MX6

    I need step-by-step instruction on how to export configuration out of CF MX6 STANDARD edition. I've looked a the following link but couldn't locate topic for this information.  http://help.adobe.com/en_US/ColdFusion/9.0/CFMLRef/index.html
    Thanks in advance

    Rick, the link you gave was to the CFML Reference. That won't help you at all in exporting server configurations.
    Instead, that's a feature of the CF Admin, and so you'd want to look at the "Configuring and Administering CF" manual, and of course you'd want it for CF 6, not CF9. They're offered at http://www.adobe.com/support/documentation/en/coldfusion/documentation.html. Unfortunately, while the links to the PDFs there work, the links to the HTML versions do not, and sadly it can't even be found via the good ole "internet wayback machine":
    But regardless, you'll face a different annoyance even if you find the docs, in that you say you're running CF Standard. That license of CF does not provide a way to export CF Admin settings. That's only an Enterprise feature, found in the Packaging & Deployment option on the left nav bar, for "ColdFusion Archives", which you won't even see in CF Standard.
    But here's a trick, which if this is a production machine you should only do at an off hour, when you can stop your web site. If you remove your CF license key (from the "system information" page in the CF Admin), that will revert CF to "Developer" mode, which is the full Enterprise functionality--but limited to allowing only up to 3 IP addresses to connect to CF. That's why you need to not only do this at an off hour, but it would be best if you could stop your web sites, or at least all but that which you need to get to the CF Admin.
    Then you can export the settings, and import them into another Enterprise or Developer edition of CF.
    As for step-by-step instructions for the process of creating the archives (a car file), there are many out on the web, such as:
    http://www.iknowkungfoo.com/blog/index.cfm/2008/4/5/Yo-Adrian-How-do-I-backup-my-ColdFusio n-Admin-settings
    http://www.quackit.com/coldfusion/coldfusion_archive_and_deploy.cfm
    or a simplified checklist at:
    http://www.code-complete.com/code/index.php?/archives/21-Using-Coldfusion-Archives-to-migr ate-datasources.html
    Hope that helps.
    /charlie arehart
    [email protected]
    Providing on-demand troubleshooting services for CF and CFBuilder
    at http://www.carehart.org/consulting

  • Indesign getting crash while exporting because of bad pdf inside file.

    Hi,
    My indesing is getting crash while exporting to pdf. I have link to pdf file inside the indesign file, when i export that indesign file to pdf indesign is getting crash without showing any error message. If i place another pdf file in same location then it is going fine and i can able to get the output pdf file. Please suggest me how can i check and correct that pdf file and is there any solution to this. Please help me i have thousands of indesign pages with the same issue. If you want pdf i can send it to your mail id. please i need fix for this problem.
    Thanks
    Kiran

    For all of you lurkers, Kiran sent me a copy of the PDF, and it looks like I found the problem (and learned a new technique which may help others in the same boat).
    I tried re-frying the file by creating an eps and distilling, but the result was the same, then I tried exporting from CS3, just for fun, and it worked, but I realized the PDF had been cropped, so I started trying differnt sections and isolated an area that failed, though that wasn't particularly helpful.
    Acrobat preflight didn't find anything that looked odd or problematic, and then I decided to run Examine Document. It came up with MetaData (no surprise) and also two items under a heading of Deleted and Cropped objects, with no preview or description. I unselected the MetaData from the list of found stuff, them clicked the Remove button in the Examine Document panel, and resaved (and while you have the opportunity to give it a new name, doing so doesn't remove the stuff untill you do the whole procedure again and save with the same name). Placed the new version of the PDF in a new file and exported no problem.

  • File Server Resource Manager will not load WMI Objects on Windows 8.0/8.1 Preview with Hyper-V and Server Tools Loaded

    Hi Folks,
    I have a problem getting "File Server Resource Manager" to start properly because WMI objects are not loading??? I don't understand this at all because I am able to access them with other Apps, etc. I have been over my Services list as well but
    have not yet discovered which Service turns on/off "File Server Resource Manager". I have looked in Windows\System32\ and I can not find SrmSvc. I found other Srm's there though. I also found the FSRM Snapin which generates the Figure below but I
    can not find it in the WMI Browser. I believe the Firewall is OKAY since I have been over that thoroughly. I do have the Server Tools Installed for Windows 8.0 or Windows 8.1 Clients as well as the Windows Updates applied, which is where I got "File Server
    Resource Manager" in the first place. I have had WMI and Powershell 3.0 Package, installed since Windows 7 but I run a repair on them anyway.
    I have read through "File Server Resource Manager could not load WMI objects on Windows Server 2012
    Article ID: 2831687" but since I don't seem to have SrmSvc the solution doesn't help me. I haven't been able to find a similar one for the Windows Client.
    If there is anything you could share on this problem I would be much obliged.
    Thanks again,
    Crysta
    PhotM Phantom of the Mobile

    Hello,
    The Windows Desktop Perfmon and Diagnostic tools forum is to discuss performance monitor (perfmon), resource monitor (resmon), and task manager, focusing on HOW-TO, Errors/Problems, and usage scenarios.
    As the question is off topic here, I am moving it to the
    Where is the Forum... forum.
    Karl
    When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer.
    My Blog: Unlock PowerShell
    My Book:
    Windows PowerShell 2.0 Bible
    My E-mail: -join ('6F6C646B61726C406F75746C6F6F6B2E636F6D'-split'(?<=\G.{2})'|%{if($_){[char][int]"0x$_"}})

  • Using LDIFDE to Export/Import configuration

    Hi All,
    I need to create a "copy" of a domain using LDIFDE. To do that, I exported the Configuration, Schema, OUs, Users and Groups. I'm having plenty of troubles during the import, so I wanted to clarify a few things:
    1) What order should the data be imported in? I was thinking importing Schema, then Configuration, then OUs, followed by Groups and finally Users
    2) Is there an easy way to remove the extra spaces from the LDIFDE extract? I did a search and replace in notepad to change the domain from DC=abc,DC=com to DC=xyz,DC=com, but there are lines where the original DC is split which is a royal pain to clean
    up!
    3) When doing an import from Schema or Configuration, I get this error
    PS C:\tmp> ldifde -i -f .\schema_export.ldf -v -j C:\tmp\
    Connecting to "mydomain.xyz.com"
    Logging in as current user using SSPI
    Importing directory from file ".\schema_export.ldf"
    Loading entries
    1: CN=Schema,CN=Configuration,DC=xyz,DC=com
    Add error on entry starting on line 1: Unwilling To Perform
    The server side error is: 0x2079 The specified instance type is not valid.
    The extended server error is:
    00002079: SvcErr: DSID-03330968, problem 5003 (WILL_NOT_PERFORM), data 0
    0 entries modified successfully.
    An error has occurred in the program
    I can't figure out why this is happening.
    Any help will be much appreciated :)

    > I need to create a "copy" of a domain using LDIFDE. To do that, I
    > exported the Configuration, Schema, OUs, Users and Groups. I'm having
    > plenty of troubles during the import, so I wanted to clarify a few things:
    Why would you need to import schema and configuration? And why do you
    not simply join a DC to your domain, take it down and do metadata
    cleanup, then start this new DC in its own environment? Much simpler
    than your approach, I believe :)
    > 1) What order should the data be imported in? I was thinking importing
    > Schema, then Configuration, then OUs, followed by Groups and finally Users
    That's what I would think, too.
    > 1: CN=Schema,CN=Configuration,DC=xyz,DC=com
    > Add error on entry starting on line 1: Unwilling To Perform
    "Add" for what? What's the content of this file?
    Martin
    Mal ein
    GUTES Buch über GPOs lesen?
    NO THEY ARE NOT EVIL, if you know what you are doing:
    Good or bad GPOs?
    And if IT bothers me - coke bottle design refreshment :))

  • Incorrect functionality of Embedded tag in html page, displaying object on top of all layers of Adobe air application native window

    Title
    Incorrect functionality of embed tag in html loader for adobe air development
    Description
    Problem Description: If we had loaded youtube.com video url in a view stack and navigate to other index of stack or away from we UI screen within the same native window video or embeded tag of flash player or any other embed object will be displayed on top of all screens layer in same position of where the object should be placed in side of html loader only.
    Steps to Reproduce:
    1) go to http://get.straweb.com/StraWebBrowser/StraWebBrowser.air download and install
    2) load 2 tabs and in the 3 tab load video player of youtube.com which will a sample video
    before completing the load of 3 tab which trying to load video from youtube.com, navigate to other tabs 1 or 2 in few second once the flash player of youtube.com video player is load it will display in the current tab or UI screen.
    3) Try navigating to other tabs than youtube.com loaded tab you see the flash player is on top it stable.
    4) navigate to 3 tab and try to navigate to other tab you can observe that so how it will not show that flash player and only visible in that 3 tab which is fine.
    Actual Result: Embedded tag of html page displaying on top of all layers of Adobe air application native window
    Expected Result: Embedded tag of html page should only displayed in side htmlloader
    This you can replicate in any adobe air plugin update and on any Hardware and Environment.
    Applicable to all sdk versions of adobe air.

    Adobe Bugbase: Bug 3823839 Incorrect functionality of embed tag in html loader for adobe air development

  • Getting ServeltContext object in different ways

    If we can get ServletContext object in our servlet using getServletContext() then what is the need for getting it using the ServletConfig object i.e by
    using config.getServletContext() where config refers to the ServletConfig object.
    Are these methods there just for convinience ?

    Just read the API documentation: http://java.sun.com/products/servlet/2.5/docs/servlet-2_5-mr2/javax/servlet/GenericServlet.html#getServletContext()

  • Keep exported image size in HTML as shown in PDF

    I have many inline formulas (imported from Word file via using mathtype) in PDF article made by ID. But when I export the articles as HTML, the images for formulas become much larger than shown in PDF version. How can i keep the exported images to the same size as they are shown the PDF file? I know I can edit the html file to specify image size, but that is the ideal work flow.
    Thank you.

    Hi Eric,
    If i'm getting you right. you have the formulas placed as the images.
    So, to keep the size fixed, In HTML export Options in image tab keep the image size as fixed.
    Snapshot to refer:
    Now you have image of same size as it appears in InDesign.

  • Line Chart: It is possible to get the object reference from a flash chart

    Hi Folks,
    hope you feel well ...
    I wan't to get the Object Reference from a Chart Flash Object using javascript in the HTML Header of a Apex Page.
    It's long time ago with Oracle/Java and so my skills are really shity :-)
    The Functionbody works, but the following error occurs: chart.refresh is not a function
    It is necessary to CAST it ? with the Class AnyChart.js ?
    After 5 hours i give up ^^ is this kind of object handling possible ? THX4HELP@ll
    Apex Page HTML Header
    <script type="text/javascript">
    function hideSID2()
    var chart = document.getElementById("*c7067437546726610*");
    chart.refresh();
    </script>
    HTML File at runtime:
    <div class="rc-body"><div class="rc-body-r"><div class="rc-content-main"><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
    codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
    width="1400"
    height="600"
    id="c7067437546726610"
    align="top"> ...

    If you are using adobe Flex Builder to develop SWF, please be sure using ExternalInterface class to expose the refresh() method.
    then you can should be able to call this method in Javascript.

  • Tables listed in Result set field selction tab against Standard Data Objects in MDO configuration

    On what basis are the tables gettting filled in the Result set field selction tab against Standard Data Objects in MDO configuration.
    Only the handler class is specified before it gets filled.
    Vivek.
    Tags edited by: Michael Appleby

    Hi Vivek,
    I would also recommend providing the version of the product either in the body of your discussion or in the tags (or both, preferred).  If you are installing it on SMP 2.3 or some other platform, please add that as well.  I have updated your tags and assigned the correct Category.  Since there are so many different technologies in SAP for Mobile, tags and Categories help the helpers find your post and help you find a solution.
    Thanks, Mike

Maybe you are looking for

  • HELP PLEASE ANYONE my ipod is messed up

    never had an issue with my 30gb ipod. until today, i just get home, a song just ends, and than, it shuts itself off, i can't turn it on, nothing (and its not dead, i checked battery life all day, it was well over half). So i open my itunes, and hook

  • Field in data file exceeds maximum length - CTL file error

    Hi, I am loading data in new system using CTL file. But I am getting error as 'Field in data file exceeds maximum length' for few records, other records are processed successfully. I have checked the length of the error record in the extract file, it

  • Window does not open to full screen???

    This one has me stumped. I recently installed / upgraded to CS5.1, set up all my preferences, keyboard shortcuts, presets, plugins. All worked fine, day in - day out,  for the last three weeks. About three days ago this anomaly appeared... When I zoo

  • Time Machine - "Can't Mount Device"

    Hi, recently my power went out and now my external HDD won't mount back to my Mac Mini! I have everything on here so any help would be great! My HDD was used as my "Time Machine" and did back ups every hour or so and now I tried restarting the comput

  • Problems saving Xcelcius Dashboards

    Hi all I'm having a few problems saving some of the dashboards I have created to my computer and also to the Crystal Server. I have created the dashboards in CX 4.5 and they will save no problems until I place a Live Office Connector on them.  As soo