Tuesday, 1 March 2022

How to check replication status of all Domain Controllers and replication status of users across Active Directory Forest

 

 
Suppose you are working in that company who have various locations and have multiple domain controllers, recently that company opened new branch in new region and you have created new Domain controller for that region and now you want to check that new domain controller able to see or replicate properly among all domain controllers and users or objects created under new domain controller able to sync properly in the Active Directory Forest.


Use below command to get all the domain controllers details in a text file (DCDetails.txt).

  •       DSQuery Server –O RDN > DCDetails.txt


Use below command to check the status of the newly created users among all domain controllers. This command gives output in text file named Detail.txt

  •         For /F “Tokens=*” %L IN (DCDetails.TXT) DO DSQuery user –DomainRoot –Name Username> Detail.txt 



Thursday, 13 January 2022

How to check the Volume Shadow Copy Service (VSS) provider/writer status

 


Problem

How to check the Volume Shadow Copy Service (VSS) provider/writer status.

Solution

To check the VSS provider/writer status.

1. Open a command window. Click Start > Run and type CMD, and then click OK.
2. At the command prompt, type vssadmin list providers, and then press ENTER.
3. Confirm that Microsoft VSS provider is listed as:
 
Microsoft Software Shadow Copy provider 1.0


 
4. Type vssadmin list writers at the command prompt, and then press ENTER.
5. Confirm that all the VSS writers are showing:
State: [1] Stable
No error


NOTE: If any errors are found with a specific writer, contact the writer's corresponding application manufacturer technical support for further assistance.

Tuesday, 28 December 2021

Basic Linux VI editor commands

 


vi is one of the most commonly used editor program and included by default with every UNIX and Linux system. vi basically operates in 3 modes, namely: 

 

  1. vi mode – the mode vi starts in 

  1. command mode – you can be in command mode from the vi mode by pressing the key colon (“:”) 

  1. input mode – in this mode user starts the actual editing of the text 


Below are some of the most commonly used vi commands in all 3 modes of operation. 

  1. vi mode commands 

Command 

Action 

k 

Move one line upwards 

l 

Move one character to the right 

h 

Move one character to the left 

w 

Move one word to the right 

W 

Move one word to the right past punctuation 

b 

Move one word to the left 

B 

Move one word to the left past punctuation 

e 

Move to the end of the current word 

1G 

Move to the beginning of the file 

H 

Move to the top of the current screen 

M 

Move to the middle of the current screen 

L 

Move to the bottom of the current screen 

Ctrl-G 

Move to the last line in the file 

Ctrl-F 

Move one screen towards the end of the file 

Ctrl-D 

Move 1/2 screen towards the end of the file 

Ctrl-B 

Move one screen towards the beginning of the file 

Ctrl-U 

Move 1/2 screen towards the beginning of the file 

Ctrl-L 

Refresh the screen 

5G 

Move to line 5 of the file (5 can be any line number) 

/string 

Find text string forward 

?string 

Find text string backward 

n 

Find forward next string instance after a string search 

N 

Find backward next string instance after a string search 

ZZ 

Save the file exit vi 

x 

Delete the character at the cursor 

X 

Delete the character behind the cursor 

dd 

Delete the line the cursor is on 

10dd 

Delete the 10 lines following the cursor 

yy 

Yank the current line 

p 

Put the yanked line below the current line 

P 

Put the yanked line above the current line 

 

  1. Command mode commands 

Command 

Action 

:g/X/s//x/g 

Global Search and replace (X=search object x=replace object) 

:r file 

Import a file into the current file 

:34 r file 

Import a file into the current file after line 34 

:w 

Write out the file to save changes 

:w file 

Write the file to named file 

:wq 

Save the file exit vi 

:w! 

Force save the file 

:q! 

Quit vi but don’t save changes 

 

  1. Input mode commands 

Command 

Action 

a 

Insert characters to the right of the cursor 

A 

Append characters to the current line 

i 

Insert characters to the left of cursor 

I 

Insert characters at the beginning of the current line 

o 

Add a new line after current line 

O 

Insert a new line above the current line 


 

Featured post

Top 10 Rare Windows Shortcuts to Supercharge Productivity

  Windows Key + X, U, U: This sequence quickly shuts down your computer. It's a great way to initiate a safe and swift shutdown without...