0

Tips & Tricks : HP TouchSmart tm2 : Screen Rotation

-

When upgrading drivers on HP TouchSmart tm2 tablet important is to keep in mind that HP Quick Launch Buttons package might disable screen auto-rotation. In order to restore that functionality remove HP Quick Launch Buttons and install older version of that package from here. Full information about package is available on HP Quick Launch Buttons web page availabel here.

Another option might be registry settings adjustment. Parameters which control screen orientation and bahevior are located under:

HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Hewlett-Packard\HP Quick Launch Buttons\Schemes\Default\8526

There are two important parameters:
Notebook_Docked_DisplayOrientation = 0
Tablet_UnDocked_DisplayOrientation = 3

Available values for those parameters:
0 – primary landscape
1 – seconday portrait
2 – seconday landscape
3 – primary portrait

1

Code snippets : Windows : Clear Event Logs

-

From script repository I did use in the past, VBscript which allows to clear EvenLog on Windows machine. I did use that on computers with Windows XP and Windows Server 2003. however, this script will work also on Windows 7 and Windows server 2008.

By default script clears EventLog on computer where script is executed. To clear logs on remote machine just modify variable strComputer and replace dot with name of the target machine.

Script will read all EvenLog files from machine and will go through them removing all events.

And here is script itself :

strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate, (Backup, Security)}!\\" _
& strComputer & "\root\cimv2")
Set colLogFiles = objWMIService.ExecQuery _
("Select * from Win32_NTEventLogFile")
For each objLogfile in colLogFiles
objLogFile.ClearEventLog()
Next
0

Code snippets : SQL : Backup and FTP Database

-

When browsing repository of all scripts I did use in past, I found one which might be interesting. What this script does is:

  • Backups database to disk (name of database stored in @dbname, patch for backup stored in @archive_path, name of backup fine stored in @fname)
  • Compresses database backup using WinRAR (full command where to find WinRAR and how ot use it stored in @archive_cmd)
  • Generates set of commands for FTP client (series of xp_cmdshell commands redirecting output to F:\Backup\ftpcmds)
  • Uploads compressed backup to FTP server using command prompt FTP client command

I had that as small procedure executed automatically with SQL Server Agent. Script is for Microsoft SQL Server and I was running it on SQL Server 2000 and 2005. Here is code for that small procedure:

 

DECLARE @fname varchar(255)
DECLARE @fname_backup varchar(255)
DECLARE @fname_archive varchar(255)
DECLARE @archive_path varchar(255)
DECLARE @dbname varchar(255)
DECLARE @archive_cmd varchar(255)
DECLARE @put_cmd varchar(255)

SET @dbname = 'dbApplication'
SET @fname = @dbname + '_' + LTRIM(STR(DAY(GETDATE())))  + '.' + LTRIM(STR(MONTH(GETDATE()))) + '.' + LTRIM(STR(YEAR(GETDATE())))
SET @archive_path = 'F:\Backup\'
SET @fname_backup = @archive_path + @fname + '.BAK'
SET @fname_archive = @archive_path + @fname + '.RAR'
SET @archive_cmd = '"C:\Program Files\WinRAR\WinRAR.EXE" a ' + @fname_archive + ' ' + @fname_backup
SET @put_cmd = 'echo put ' + @fname_archive + '>> F:\Backup\ftpcmds'

PRINT @fname_backup
PRINT @fname_archive

BACKUP DATABASE @dbname TO DISK = @fname_backup WITH INIT

EXEC xp_cmdshell @archive_cmd
EXEC xp_cmdshell 'echo open 192.168.10.101> F:\Backup\ftpcmds'
EXEC xp_cmdshell 'echo user dbupload>> F:\Backup\ftpcmds'
EXEC xp_cmdshell 'echo password123>> F:\Backup\ftpcmds'
EXEC xp_cmdshell 'echo cd DB_Backup>> F:\Backup\ftpcmds'
EXEC xp_cmdshell 'echo bin>> F:\Backup\ftpcmds'
EXEC xp_cmdshell 'echo ha>> F:\Backup\ftpcmds'
EXEC xp_cmdshell @put_cmd
EXEC xp_cmdshell 'echo bye>> F:\Backup\ftpcmds'
EXEC xp_cmdshell 'ftp -d -i -n -s:F:\BACKUP\ftpcmds'

I hope that will be handy for someone to automate databsae backups and transfers.

0

Games : Screenshots : Skyrim – Visiting Sovngard

-

(more…)

0

First look : System Center Virtual Machine Manager 2012 installation screenshots

-

Installation screenshots from System Center Virtual Machine manager 2012 installation. I did installation in my virtual LAB environment as part of excercise with System Center 2012.

(more…)

0

Tips & Tricks : ShoreTel : Logon and Logoff extension

-

Quick procedure to logon or logoff phone extension to or from ShoreTel IP phone. Steps listed below will allow to bring your phone extension to phone located in remote site and then send back to home ShoreTel IP phone. Of course both phones have to be part of same ShoreTel infrastructure (have to be managed from same ShoreTel HQ server).

(more…)

0

Games : Codes : Skyrim – finding Aldis in Solitude

-

During the quest about Angeline’s daughter it might be not possible even to find Aldis. It is possible that he died during attack on Solitude. In that case some easiest way is to bring Aldis to player 🙂

(more…)

0

Games : Codes : Skyrim – Free camera moves

-

Sometimes would be nice to hover over land of Skyrim and watch everything from above or even take some pictures of cities and places from sky. But how to do that?

Best way to fly around like a bird is to enable free camera moves. That will allow to freely move around and observe everything from above, like bird flying over Skyrim.

(more…)

2

How-to : Package virtual machine for Riverbed Steelhead with RSP

-

RSP platform installed on Riverbed allows to run VMware virtual machines on it. THat gives very powerful environment as Riverbed might become the only appliance deployed for branch office and with WAN optimization we can also provide basic services/systems to site. That gives us huge flexibility and same time no need to deploy additional systems for site can be placed on Riverbed as virtual machines. Of course that reuires special license and also additional RAM would be recommended, so we won’t suffer performance issues (additional memory can be purchased with Riverbed appliance and RSP license, so we get ready to go environment).

But it is not enough to create VMware cityual machine on PC and upload it to Riverbed. Few more steps is involved in the process and here we will go through all steps to see how to prepare virtual machine for Riverbed on Windows 7 PC with VMware Workstation 9 installed.

(more…)

0

Config snippets : Setting NTP server on Cisco IOS device

-

Quick config snippet to setup external NTP server to synchronize time on Cisco IOS router.

labisr-01(config)#ip name-server 4.2.2.2
labisr-01(config)#ntp server 0.europe.pool.ntp.org
Translating "0.europe.pool.ntp.org"...domain server (4.2.2.2) [OK]
labisr-01(config)#clock timezone GMT 0
labisr-01(config)#
Please note that first I setup nameserver on router to be able to resolve NTP server FQDN.

Once NTP server is set we can check status of it:

labisr-01#sh ntp associations
address         ref clock     st  when  poll reach  delay  offset    disp
*~88.191.227.26    82.197.188.130    3    37    64  377    38.7    2.04     1.4
* master (synced), # master (unsynced), + selected, - candidate, ~ configured
labisr-01#
labisr-01#sh ntp status
Clock is synchronized, stratum 4, reference is 88.191.227.26
nominal freq is 250.0000 Hz, actual freq is 250.0000 Hz, precision is 2**18
reference time is D442C30E.7A93ED17 (22:58:22.478 GMT Mon Nov 5 2012)
clock offset is 2.0449 msec, root delay is 71.69 msec
root dispersion is 61.25 msec, peer dispersion is 1.36 msec
labisr-01#
Page 10 of 17« First...89101112...Last »