Showing posts with label Windows 10 Professional. Show all posts
Showing posts with label Windows 10 Professional. Show all posts

Tuesday, December 12, 2017

How do you find details about your computer operating system using Windows Management Instrumentation?

Call up WMIC from a command prompt to begin as shown.e  It is better to start the CMD  as an adminsitrator.
-----------
C:\WINDOWS\system32>Wmic
wmic:root\cli>
----------------
Now you are at the root, use the following statement to find the help file for the Operating System (OS):
------------
wmic:root\cli>OS /?
OS - Installed Operating System/s management.
HINT: BNF for Alias usage.
( [WMIObject] | [] | [] ) [].

USAGE:
OS ASSOC []
OS CALL []
OS CREATE
OS DELETE
OS GET [] []
OS LIST [] []
OS SET []

-------------------
You should get help for each of these as well. Here is an example for OS Get:
Execute the following statement:
-------------
wmic:root\cli>OS GET /?
Property get operations.
USAGE:
GET [] []
NOTE: ::= |

The following properties are available:
Property                                Type                    Operation
========                                ====                    =========
BootDevice                              N/A                     N/A
BuildNumber                             N/A                     N/A
BuildType                               N/A                     N/A
CSDVersion                              N/A                     N/A
CSName                                  N/A                     N/A
CodeSet                                 N/A                     N/A
CountryCode                             N/A                     N/A
CurrentTimeZone                         N/A                     N/A
Debug                                   N/A                     N/A
Description                             N/A                     N/A
Distributed                             N/A                     N/A
EncryptionLevel                         N/A                     N/A
ForegroundApplicationBoost              N/A                     N/A
FreePhysicalMemory                      N/A                     N/A
FreeSpaceInPagingFiles                  N/A                     N/A
FreeVirtualMemory                       N/A                     N/A
InstallDate                             N/A                     N/A
LastBootUpTime                          N/A                     N/A
LocalDateTime                           N/A                     N/A
Locale                                  N/A                     N/A
Manufacturer                            N/A                     N/A
MaxNumberOfProcesses                    N/A                     N/A
MaxProcessMemorySize                    N/A                     N/A
Name                                    N/A                     N/A
NumberOfLicensedUsers                   N/A                     N/A
NumberOfProcesses                       N/A                     N/A
NumberOfUsers                           N/A                     N/A
OSLanguage                              N/A                     N/A
OSProductSuite                          N/A                     N/A
OSType                                  N/A                     N/A
Organization                            N/A                     N/A
OtherTypeDescription                    N/A                     N/A
PlusProductID                           N/A                     N/A
PlusVersionNumber                       N/A                     N/A
Primary                                 N/A                     N/A
QuantumLength                           N/A                     N/A
QuantumType                             N/A                     N/A
RegisteredUser                          N/A                     N/A
SerialNumber                            N/A                     N/A
ServicePackMajorVersion                 N/A                     N/A
ServicePackMinorVersion                 N/A                     N/A
SizeStoredInPagingFiles                 N/A                     N/A
Status                                  N/A                     N/A
SystemDevice                            N/A                     N/A
SystemDirectory                         N/A                     N/A
SystemDrive                             N/A                     N/A
TotalSwapSpaceSize                      N/A                     N/A
TotalVirtualMemorySize                  N/A                     N/A
TotalVisibleMemorySize                  N/A                     N/A
Version                                 N/A                     N/A
WindowsDirectory                        N/A                     N/A
The following GET switches are available:
/VALUE                       - Return value.
/ALL(default)                - Return the data and metadata for the attribute.
/TRANSLATE:      - Translate output via values from
.
/EVERY: [/REPEAT:] - Returns value every (X interval) seconds, If /REPEAT specified the command is executed times.
/FORMAT:   - Keyword/XSL filename to process the XML results.

NOTE: Order of /TRANSLATE and /FORMAT switches influences the appearance of output.
Case1: If /TRANSLATE precedes /FORMAT, then translation of results will be followed by formatting.
Case2: If /TRANSLATE succeeds /FORMAT, then translation of the formatted results will be done.
------------
Now here are a few things about my operating system (Windows 10 Professional)
----------------
wmic:root\cli>OS GET BootDevice
BootDevice
\Device\HarddiskVolume2

wmic:root\cli>OS GET SerialNumber
SerialNumber
00330-80000-00000-AA401

wmic:root\cli>OS GET Manufacturer
Manufacturer
Microsoft Corporation

wmic:root\cli>OS GET Version
Version
10.0.17025

------------
This was just a sample of what you can find. You can try a whole lot on yourself.

Tuesday, September 5, 2017

Do you know these Power-Shell commands for Network Connectivity?

These are some of the commands that you may need to note. Although similar information is obtained by the Windows commands as well.

This is the version of Power Shell I am running:
-----------
PS C:\Users\Owner> $PSVersionTable.PSVersion

Major  Minor  Build  Revision
-----  -----  -----  --------
5      1      16278  1000

------------------------------------------------

Test_Connection:

Test-Connection Sends Internet Control Message Protocol request packets to one or more computers

----------------
PS C:\Users\Owner> Test-Connection Hodentek9

Source        Destination     IPV4Address      IPV6Address                              Bytes    Time(ms)
------        -----------     -----------      -----------                              -----    --------
HODENTEK9     Hodentek9       192.168.0.10     fe80::dd68:c5d6:8d40:f244%2              32       0       
HODENTEK9     Hodentek9       192.168.0.10     fe80::dd68:c5d6:8d40:f244%2              32       0       
HODENTEK9     Hodentek9       192.168.0.10     fe80::dd68:c5d6:8d40:f244%2              32       0       
HODENTEK9     Hodentek9       192.168.0.10     fe80::dd68:c5d6:8d40:f244%2              32       0    
-----------
PS C:\Users\Owner> Test-NetConnection Hodentek9

ComputerName           : Hodentek9
RemoteAddress          : fe80::dd68:c5d6:8d40:f244%2
InterfaceAlias         : Wi-Fi
SourceAddress          : 2605:e000:d803:1800:4978:3d25:95cf:ed61
PingSucceeded          : True
PingReplyDetails (RTT) : 0 ms
----------------------------------------------------

You can also run commands as shown here in Power Shell's Command Addon window as shown
here.


Resolve_DnsName

Resolve-DnsName Runs a DNS name query resolution for specified name
-----------
PS C:\Users\Owner> Resolve-DnsName Hodentek9
Name                                           Type   TTL   Section    IPAddress                             
----                                           ----   ---   -------    ---------                             
Hodentek9                                      AAAA   1200  Question   fe80::dd68:c5d6:8d40:f244             
Hodentek9                                      AAAA   1200  Question   2605:e000:d803:1800:dd68:c5d6:8d40:f244
Hodentek9                                      AAAA   1200  Question   2605:e000:d803:1800:4978:3d25:95cf:ed61
Hodentek9                                      A      1200  Question   192.168.0.10                          
* you can get the same information more descriptive using the Windows Command, IPCONFIG
------------------------------------------------------------------------------
 Test-DnsServer
Test-DnsServer Tests a computer for being a DNS Server

The command is not found in Windows 10 Professional. Perhaps this is to be run on a Windows Server OS

Help for Connection:
----------
PS C:\Users\Owner> get-help Test-Connection

NAME
    Test-Connection
   
SYNTAX
    Test-Connection [-ComputerName] [-AsJob] [-DcomAuthentication {Default | None | Connect | Call
    | Packet | PacketIntegrity | PacketPrivacy | Unchanged}] [-WsmanAuthentication {Default | Basic |
    Negotiate | CredSSP | Digest | Kerberos}] [-Protocol {DCOM | WSMan}] [-BufferSize ] [-Count ]
    [-Impersonation {Default | Anonymous | Identify | Impersonate | Delegate}] [-ThrottleLimit ]
    [-TimeToLive ] [-Delay ]  []
   
    Test-Connection [-ComputerName] [-Source] [-AsJob] [-DcomAuthentication {Default |
    None | Connect | Call | Packet | PacketIntegrity | PacketPrivacy | Unchanged}] [-WsmanAuthentication
    {Default | Basic | Negotiate | CredSSP | Digest | Kerberos}] [-Protocol {DCOM | WSMan}] [-BufferSize
    ] [-Count ] [-Credential ] [-Impersonation {Default | Anonymous | Identify |
    Impersonate | Delegate}] [-ThrottleLimit ] [-TimeToLive ] [-Delay ]  []
   
    Test-Connection [-ComputerName] [-DcomAuthentication {Default | None | Connect | Call | Packet
    | PacketIntegrity | PacketPrivacy | Unchanged}] [-WsmanAuthentication {Default | Basic | Negotiate |
    CredSSP | Digest | Kerberos}] [-Protocol {DCOM | WSMan}] [-BufferSize ] [-Count ]
    [-Impersonation {Default | Anonymous | Identify | Impersonate | Delegate}] [-TimeToLive ] [-Delay
    ] [-Quiet]  []

------------------------------------