Wednesday, December 11, 2013

Script for File copy Older than X Days | ROBOCOPY Batch file

Hey All,

Issue :

One more challenge I faced yesterday.
Robocopy batch files which I scheduled were getting failed with error code 0x1

Observation : All robocopy schedules were getting failed with error code 0x1
One more thing I noticed is that the Task manager was showing multiple instances of Robocopy exe.

Task manager gave way to the solution

Solution :

After googling number of forums, I found switch to exit the Robocopy at the end. I added it at the end of command, but it did not work.

It gave error 0x80 :  Quitting : /QUIT Specified on Command Line.

After that I tried one more option. Defining one more line of code and specifying the /QUIT option there.

e.g.
*****************************************************************
@echo off
For /f "tokens=2-4 delims=/ " %%a in ('date /t') do (set mydate=%%c-%%a-%%b)
For /f "tokens=1-2 delims=/:" %%a in ('time /t') do (set mytime=%%a%%b)
robocopy "\\share\source" "D:\Destination" *.xml /MAXAGE:3 /LOG+:"D:\Logs\%mydate%.log" /NP
 

robocopy /QUIT
*****************************************************************
 What does above script does :
  • Copies files which are not older than 3 Days from source to destination
  • Stores the logs Datewise (You can add %mytime% if you want time also)
  • Copies only XML extension (You can specify *.* if you want to copy all files)
Its working fine now.

Hope this helps to you as well.

Tuesday, September 17, 2013

How to install Hyper-V Role on VMware ESXi Virtual Machine

Problem : 
Can not install Hyper-V Role on VMware Virtual Machine

Environment : 
VMware ESXi 5.X

Solution :

1. Go to ESXi Server Shell by using putty or similar utility.

2. Locate file config in /etc/vmware folder
# cat /etc/vmware/config
libdir = "/usr/lib/vmware"
authd.proxy.vim = "vmware-hostd:hostd-vmdb"
authd.proxy.nfc = "vmware-hostd:ha-nfc"
authd.proxy.nfcssl = "vmware-hostd:ha-nfcssl"
authd.proxy.vpxa-nfcssl = "vmware-vpxa:vpxa-nfcssl"
authd.proxy.vpxa-nfc = "vmware-vpxa:vpxa-nfc"
authd.fullpath = "/sbin/authd"
authd.soapServer = "TRUE"
vmauthd.server.alwaysProxy = "TRUE"


3. Add vhv.allow = "TRUE" entry at the end of file using VI utility, it will look like below :
# cat /etc/vmware/config
libdir = "/usr/lib/vmware"
authd.proxy.vim = "vmware-hostd:hostd-vmdb"
authd.proxy.nfc = "vmware-hostd:ha-nfc"
authd.proxy.nfcssl = "vmware-hostd:ha-nfcssl"
authd.proxy.vpxa-nfcssl = "vmware-vpxa:vpxa-nfcssl"
authd.proxy.vpxa-nfc = "vmware-vpxa:vpxa-nfc"
authd.fullpath = "/sbin/authd"
authd.soapServer = "TRUE"
vmauthd.server.alwaysProxy = "TRUE"

vhv.allow = "TRUE"

4. Power off VM, where you want to ENABLE Hyper-V Role.

5. Goto VM folder location and edit its VMX file.
# cd /vmfs/volumes/datastore7.44/WINDOWS8PC2

6. Edit WINDOWS8PC2.vmx file using VI Editor and Change the guestOS = "windown8-64" to  guestOS = "winhyperv"
# vi WINDOWS8PC2.vmx

7. Thats it... You are Done!!! Power ON the VM and you are ready to install the Hyper-V Role on it.

Friday, August 30, 2013

EMCOPY | ERROR (1722) Unable to get the domain SID info from DomainController

Scenario:

While using EMC Utility EMCOPY following errors get encountered.

Errors : 
- ERROR (1722) : Unable to get the domain SID info from DomainController
- ERROR (1722) : Unable to retrieve the primary group of the default user Domain\User from \\DomainController
- ERROR (1727) : Lookup account sid from \\SHARE failed

Resolution :
- Make sure that the Source and the Destination is pingable.
- Make sure that the DNS Server is having both Source and Destination entries.
- If you dont have permission to do the chages on DNS Server, then you can make HOST File entry of source and destination in C:\Windows\System32\Drivers\etc\Hosts file from where you are running the EMCOPY Command.

Thursday, August 29, 2013

Windows Server 2008 R2 always boots in recovery mode

If you are facing below Issues : 
- You faced the Windows Server 2008 R2 Clean boot issue
- Windows Server 2008 R2 starts in recovery mode
- After installing windows updates on Windows server 2008 R2 system goes in recovery mode after reboot
- Safe mode also doesn't work in above case and get stuck at classpnp.sys

Then this is the solution for all above:

1. Boot into Windows Recovery Mode
2. Open Command Prompt
3. Type:

sfc /SCANNOW /OFFBOOTDIR=C:\  /OFFWINDIR=C:\Windows

4. Goto following location :

C:\Windows\winsxs\
 Check out for pending.xml file.
If it is present, then DELETE it.

5. Reboot the system.

6. Select normal boot mode. 

You have done it!

Thursday, March 14, 2013

Karbonn A5 Rooting and Installing ClockworkMod Recovery


Karbonn A5 ClockworkMod Recovery Installation and ROM Update

  1. Install ADB Drivers.
    • Plug the USB cable connected to the computer, the computer will notice a new hardware device called TianyuHSUSB, click Next and select "Install from a list or specific location", then click Next.
    • Unzip the downloaded file Driver.zip above, click on "Browse", find the extracted driver
    • Repeat the above steps until the popup window does not appear anymore.

    http://goo.gl/6xcIL

  2. Continue to install drivers for your ADB, adb_driver select the folder, click "OK" button, click "Next" to start installing the drivers of ADB.
    • If the driver does not show up the settings window ADB, we can install manually in Device Manager.
     
  3. Update the Baseband of your Mobile using method mentioned in the Post  http://forum.xda-developers.com/showthread.php?t=2036053
  4. If you are not performing above step(Baseband Upgradation), your mobile will not accept the ROMS which you are going to deploy.
  5. Install CWM Recovery. Start the mobile, press and hold Volume Up key and power button until the screen appears green, then take your hands off, plug the USB cable into the computer.
    • Unzip the file W619-CWM-English.zip into a certain directory.
    • After you unzip it, open recovery.bat, a command line window will appear, in each window, press any key to reboot,it is installed ClockworkMod Recovery v.5.0. 2.8

     http://www.mediafire.com/?k1qoddaa2xezz95

  6. Press any key. If you press any key, but the window just hangs forever waiting for device i.e. you have not installed the correct driver for the ADB, disconnect the USB cable and reinstall. 
  7. After this step will reboot the machine we have it for your Recovery.
  8. To get into Recovery. Start the mobile again, press and hold Volume Up key and power button until the screen appears green, held next to the red screen, then quickly put out.

How to Install ROM?

1) Download the ROM zip

2) Place that zip in the root of your sd card

3) Go to CWN recovery mode

4) Factory Reset/wipe data

5) Wipe Cache

6) Goto advanced option and wipe dalvik cache and battery stats

7) Then, Flash the ROM

8) Again wipe cache 4 times & Reboot

 

Friday, February 8, 2013

Karbonn A5 Mobile Drivers


Here is the attachment for Drivers which I got from various sources for Karbonn Android Mobiles.

You can use these drivers for Debugging, Modem as well as other number of things

It worked well on Windows 8 Pro.

Mobile Tested : Karbonn A5

Download it From  : http://goo.gl/6xcIL


Thanks n do comment.

Solved : The user profile failed to attach. The process cannot access the file becase it is being used by another process

Issue :  The user profile failed to attach. Please contact Support. Status : 0x0000000B, Message: Cannot open virtual disk Error Code: 0x000...