Posted in PowerShell, Windows, Windows Server

Windows: How to change the network from Public to Private?


On my Windows 10, I found the network is set to Public network. That means you can’t share anything to/from other computers. When you connect to a new network, Windows gives you an option to share files with another computer on the network. If you check that box, the network is flagged as Private. If you missed it, the network is flagged as Public. It looks like this:

PublicNetwork

I tried to change that network back to the Private network. For some reason, Windows 10 didn’t give me any to option to change the network type anywhere in GUI settings.

But I found how to do it in PowerShell. If you want to change the network type, open the PowerShell with Administrative Privileges (Right click on PowerShell, Run as Administrator) and run these commands:

Run this command and note down “InterfaceAlias” of the network you want to change.

Get-NetConnectionProfile

Store the Network connection profile of the network to a variable (enter the interface alias you noted down from the previous command) :

$netprofile = Get-NetConnectionProfile -InterfaceAlias <Interface Alias name>

Change the Network Category to “Private” or “Public” in the object stored in $netprofile:

$netprofile.NetworkCategory = "Private"

Set the network profile with the modified object:

Set-NetConnectionProfile -InputObject $netprofile

You can close the PowerShell now. Check your network, it should be changed now.

PrivateNetwork

Posted in Windows, Windows Server

Group Policy is failed to update on Windows 10 computer


On my Windows 10 computer, I found Group Policy is not being applied anymore. If I ran group policy update on a administrative command shell, I get this:

PS C:\WINDOWS\system32> gpupdate /force
Updating policy…
Computer Policy update has completed successfully.
User Policy could not be updated successfully. The following errors were encountered:

The processing of Group Policy failed. Windows could not determine if the user and computer accounts are in the same forest. Ensure the user domain name matches the name of a trusted domain that resides in the same forest as the computer account.

To diagnose the failure, review the event log or run GPRESULT /H GPReport.html from the command line to access information about Group Policy results.

So after some research I found the issue and fixed it. The solution is

Make the freaking NETLOGON service to start automatically and start the service.

Did this solution helped you? leave me a reply here.

Posted in Windows

How to Create a bootable Windows 2012 R2 USB Disk? (applies to Windows 8.1 also)


Pre-requisites: 7-Zip software (Download it from here: http://7-zip.org/), Windows 2012 (R2) ISO (or Windows 8.1 ISO), 8GB or more USB disk

  • Open Command Prompt in elevated mode (Run as Administrator)
  • Type diskpart and press Enter
  • Type list disk and press Enter. Note the list of existing disks.
  • Insert the USB Disk
  • Type list disk and press enter again. Note the new disk showed up which is our USB disk. I assume the new disk is 2 for example purpose.
  • Type select disk X where X is your USB disk. E.g., select disk 2. Press Enter.
  • Type clean and press enter.
  • Type create partition primary and press enter to create primary partition 1.
  • Type select partition 1 and press enter.
  • Type active and press enter to make the partition 1 active
  • Type format fs=ntfs and press enter. This will format the partition 1 as NTFS volume.
  • Type assign and press enter to assign the USB disk to a drive letter.

 

  • Now right click on Windows Server 2012 R2 or Windows 8.1 ISO file, select 7-Zip –> Extract Files…
  • Select your USB disk to extract the ISO contents to the USB disk

That’s all. Boot the server or computer using the bootable USB disk.

Did it help you? Leave me a Thanks.

Posted in Windows

Outlook 2013 (&2010): Pictures in Signature–How to?


In Outlook 2013 (& 2010) if you paste or insert an picture (e.g., Logo) in Signature Editor, it is not resizable. You are stuck and not able to do a correct sized picture in Logo. But No worries. There is an very simple trick that you can make the signature however you want.

  • Click New E-mail in Outlook 2013 (or 2010)
  • Type and insert the picture and make the signature that way you want.

image

  • Now Copy the whole thing in the compose window.
  • Click Insert –> Signature –> Signatures..
  • Click New and type a name, click OK.
  • Paste the copied signature

That’s it. Enjoy. Smile

Posted in Troubleshooting, Windows

Windows 7: Network Card disconnect on high usage


My computer was keep disconnecting from network, I think it happens when I am doing high network usage. After I remove the network cable and reconnect, it works for while.

System Event log has few of these,

Log Name: System
Source: Microsoft-Windows-DNS-Client
Date: 4/19/2011 6:23:00 PM
Event ID: 1014
Task Category: None
Level: Warning
Keywords:
User: NETWORK SERVICE
Computer: computername.company.com
Description:
Name resolution for the name yp.shoutcast.com timed out after none of the configured DNS servers responded.

I found this FORUM POST with few solutions.  The one worked for me is to disable Receive Side Scaling in network card advanced properties.  I hope this helps if anyone suffers from this nagging issue.

image

Posted in Windows

Open Windows Explorer to My Computer (instead of Libraries)


I heard my friends say Windows 7 Explorer opens to Libraries page automatically. They have been used to see “My Computer” page in Explorer like below.

image

No Fear. To open Explorer to “My Computer” by default, follow the steps below.

  • If you pinned Explorer to the task bar (by default Windows 7 does it), right click on Explorer, and right click on “Windows Explorer”. Select properties.

image

  • On the properties page, copy & page this on Target text box: %SystemRoot%explorer.exe /root,::{20D04FE0-3AEA-1069-A2D8-08002B30309D}

image

  • Click Ok.

Try clicking on the Windows Explorer icon on the task bar.  Did you find your old love of “My Computer” page?

Posted in Windows

Configure applications as “Run as an Administrator” every time


User Account Control kicks in when you try to run some applications (e.g., Administrative tools), you have to click UAC window. Or some times you simple want to run an application with high privileges and you hate every time you had to right click and select “Run as an Administrator” option. Here is the easy way.

1. On the Start menu, locate the program that you want to always run as an administrator.
2. Right-click the application’s shortcut, and then click Properties.
3. In the Properties dialog box, click the Compatibility tab.
4. Do one of the following:

  • To apply the setting to the currently logged-on user, select the Run This Program As An Administrator check box, and then click OK.
  • To apply the setting to all users on the computer and regardless of which shortcut is used to start the application, click Change Setting For All Users to display the Properties dialog box for the application’s .exe file, select the Run This Program As An Administrator check box, and then click OK twice.
Posted in Windows

Windows 7: Defrag hard disk from command line or schedule a task manually


Windows 7 defrag GUI tool is simple and easy.  Click Start Orb, type Defrag and Press Enter. You can configure schedule to defrag automatically on your specified time. I usually choose the day time, because my laptop is off during night.

image

Here are command line options for more control (check out /X option).

Defrag <volume> | /C | /E <volumes> [/A | /X | /T] [/H] [/M] [/U] [/V]
The options for Defrag.exe are:

  • <volume> The drive letter or mount point of the volume to defragment.
  • /C Defragment all local volumes on the computer.
  • /E Defragment all local volumes on the computer except those specified.
  • /A Display a fragmentation analysis report for the specified volume without defrag¬menting it.
  • /X Perform free-space consolidation. Free-space consolidation is useful if you need to shrink a volume, and it can reduce fragmentation of future files.
  • /T Track an operation already in progress on the specified volume.
  • /H Run the operation at normal priority instead of the default low priority. Specify this option if a computer is not otherwise in use.
  • /M Defragment multiple volumes simultaneously, in parallel. This is primarily useful for computers that can access multiple disks simultaneously, such as those using SCSI- or SATA-based disks rather than disks with an IDE interface.
  • /U Print the progress of the operation on the screen.
  • /V Verbose mode. Provides additional detail and statistics.

I like this geek cartoon, by the way. Found at http://geekandpoke.typepad.com/geekandpoke/2010/11/geek-gen-x.html

Defrag2

Posted in Windows

IE InPrivate Filtering – Enable it by default


If you don’t know what’s InPrivate browsing, here is brief introduction (or read it here: http://windows.microsoft.com/en-gb/windows-vista/What-is-InPrivate-Browsing)

InPrivate Browsing enables you to surf the web without leaving a trail in Internet Explorer. This helps prevent anyone else who might be using your computer from seeing where you visited and what you looked at on the web. You can start InPrivate Browsing from the new tab page or the Safety button.

Now you know or already know what it is, you may want to enable it every time you open Internet Explorer. Here is how you can do it.

  1. Open Registry Editor (Regedit.exe)
  2. Navigate to HKCUSoftwareMicrosoftInternet ExplorerSafetyPrivacIE
  3. Create new DWORD key named StartMode and set the value 1.
  4. Close Registry Editor
  5. That’s it.

Enjoy your InPrivate browsing.

Posted in Windows

Multiple Monitors–different wallpapers (Free Open Source Tool)


Wish you had different wallpapers for each monitor on your computer? Is one of your big monitor doesn’t display the wallpaper correctly due to different sized monitors? No worries..there is free software, named WallMaster, does the job.

ScreenShot.png

WallMaster provides the following features:

  • Completely independent selection of wallpapers for each screen
  • Random selection of wallpapers based on a user defined directory
  • User defined interval for changing wallpapers
  • Selection of a different background color for different monitors
  • Multiple options for placing a wallpaper on a screen
    • Center
      • Centers image, cropping it to the limitations of the screen
    • Stretch
      • Stretch the image to take up the entire screen, distorting aspect ratio
    • StretchRatio
      • Stretch the image to take up the entire screen, maintaining aspect ratio
      • This may result in either horizontal or vertical bars around the image
    • Magic
      • Center an image when it is smaller than the screen, otherwise use StretchRatio
  • Dynamically discovers screen the number of screens
  • Resize images automatically when the screen resolution changes
  • Hides in notification tray on minimize

Head over to http://wallmaster.codeplex.com/ to download the software.