Monday, 25 October 2010

Backup Exec 2010 SBS/Sharepoint Database Errors

Been noticing a few problems recently with Backup Exec 2010 complaining about the default SBS 2008 databases.

Specifically the logs say that the transaction logs for these databases are not being backed up and the recovery mode should be set to simple.  However, it is not straight forward to do this, particularly as the SQL Management Studio is not part of SBS

These are the errors as shown in the Backup Exec logs:

Backup- XXXXXXXX\MICROSOFT##SSEEV-79-40960-37914 - Database WSS_Content is configured to maintain transaction logs. Transaction log backups are not being performed. This will result in the log growing to fill all available disk space. Regular log backups should be scheduled or the database should be changed to the simple recovery mode.

Backup- WebApplication\Content-DB 1 (XXXXXXXX\MICROSOFT##SSEE\SharePoint_AdminContent_d4e397f2-a27a-48a0-a628-d25db6672bab)V-79-40960-37914 - Database SharePoint_AdminContent_d4e397f2-a27a-48a0-a628-d25db6672bab is configured to maintain transaction logs. Transaction log backups are not being performed. This will result in the log growing to fill all available disk space. Regular log backups should be scheduled or the database should be changed to the simple recovery mode.

Backup- SBS SharePoint\Content-DB 1 (XXXXXXXX\MICROSOFT##SSEE\ShareWebDb)V-79-40960-37914 - Database ShareWebDb is configured to maintain transaction logs. Transaction log backups are not being performed. This will result in the log growing to fill all available disk space. Regular log backups should be scheduled or the database should be changed to the simple recovery mode.

Backup- ConfigurationV3-DB (XXXXXXXX\MICROSOFT##SSEE\SharePoint_Config_29c26fca-17b8-48c1-9704-b869932abcb6)V-79-40960-37914 - Database SharePoint_Config_29c26fca-17b8-48c1-9704-b869932abcb6 is configured to maintain transaction logs. Transaction log backups are not being performed. This will result in the log growing to fill all available disk space. Regular log backups should be scheduled or the database should be changed to the simple recovery mode.

I've put the database names in bold above to make it easier to pick them out, the long alphanumeric strings in two of them will be different on each server so be sure to substitute the correct ones when running the commands below.

To set the recovery mode to simple for these databases, use osql from the command prompt as follows:

C:> osql -E -S \\.\pipe\MSSQL$MICROSOFT##SSEE\sql\query
1> ALTER DATABASE WSS_Content SET RECOVERY SIMPLE
2> go
1> ALTER DATABASE ShareWebDb SET RECOVERY SIMPLE
2> go
1> ALTER DATABASE [SharePoint_AdminContent_d4e397f2-a27a-48a0-a628-d25db6672bab] SET RECOVERY SIMPLE
2> go
1> ALTER DATABASE [SharePoint_Config_29c26fca-17b8-48c1-9704-b869932abcb6] SET RECOVERY SIMPLE
2> go

NOTE: That the last two with the long alphanumeric strings need to be surrounded by square brackets [], or you will get a syntax error complaining about the '-' symbol.  I originally thought I would be clever and just quote these database names, but then I got an error saying that 'recovery' is not a recognized option.  Square brackets fixes this.



Monday, 1 February 2010

On iPads and Google OS

There is an awful lot of noise at the moment about the iPad (which I guess I'm adding to...) but so many people seem to be really missing the point and this reminds me of a similar mis-perception about the Google OS recently.

It seems to me that Google and Apple are the only companies that really understand what personal computing is evolving into, both of them have a clear (but very different) vision of what is coming next and they are both totally blindsiding the rest of the tech industry.

When the Google OS was announced all my (techie) friends were saying "Whats the point of that?" and bemoaning the fact that everything was "in the cloud" and run through a browser - typical objections were
  1. No local applications
  2. Useless without internet access
  3. Why buy one of these instead of a laptop ?
All of these miss the point.  With Google Gears, browser applications can quite happily run locally, but you probably wont want to much - the vast majority of computer use these days is in fact internet use, so if you aren't connected you may as well switch the thing off.
As for the last item - "Why buy one of these instead of a laptop?" - the simple answer is that you don't.  Buy one that is.  Instead, you walk into Carphone Warehouse, sign up for the latest mobile phone on a 24 month contract and they chuck in a Google OS netbook free.
"But I don't trust Google with all my data." - fine, don't then, but most people really couldn't care less, and for them it is a bonus that all their data is in the cloud and backed up without them ever having to think about it.

What has this got to do with the iPad ?

Well the technically savvy are showing a similar lack of clue about this.  The main objections to the iPad seem to be:
  1. It's a big iPod
  2. The Kindle is better because it has e-ink
  3. The Kindle is better because it has weeks of battery life
  4. I can do more with my netbook
  5. Why didn't they put a phone (camera, gps, other....) in it ?
1. It's a big iPod - Yes it is.  And?
"But why would I pay out for one of these when it is just a big iPod?" - because, it is a big iPod.  All the people trotting out this argument seem to be saying that they already have an iPod and even though it only has a small screen they still play games, email, surf the web, read books, watch films etc. on it so why would they want a big iPod ?  Surely, surely, if you are already doing all this on a teeny little iPod screen, it's going to be so much better on an iPad?

2. The Kindle is better because it has e-ink - first off, I'd like to point out that the Kindle is really fugly, but that aside, the e-ink displays I've seen are grey, grainy and slow, and I would much, much, rather read off an LCD.  "But reading off the computer gives me eye strain" - I spend at least 8 hours a day, reading from an LCD and don't have eye strain, but then I wear the reading glasses that I am supposed to, and make sure I have proper lighting around the screen.  Also, e-ink doesn't do glossy magazines.

3. The Kindle is better because it has weeks of battery life - I don't need several weeks of battery life.  The iPad will (according to Apple) play video for 10 hours straight, and if you've just spent ten hours on the damn thing then it is probably time for bed anyway - just plug it in before you go to sleep hugging it.  "But what about when I go on holiday - a Kindle will last for the whole two weeks!" - they don't have plug sockets where you go on holiday ?  Well, maybe they don't, but if you are on a "get away from it all" kind of vacation then you probably want to be laying off the tech a bit anyway.

4.  I can do more with my netbook - Yes, you can do more with your netbook, and for the same kind of price to boot, and this goes to the heart of what I have been talking about.  Before the iPad and Google OS, the IT industry completely misunderstood netbooks too.
The iPad is what netbooks were always supposed to be - and were, originally.  Netbooks are just seen as small laptops now, but this was not the  original market - they were intended to be web and email devices in a handy portable form factor.  It was only when the major manufacturers saw netbooks selling like hot cakes and decided to jump on the bandwagon with devices that were actually small laptops instead.
The laptop, by contrast, has for a long time been intended as a replacement for the standard personal computer, but by shrinking it down further it becomes far less usable as such and also fails to deliver the value for money and simplicity of the netbook ideal.
Now when people complain that the iPad can't do what a netbook can, they perfectly demonstrate their failure to understand either.

5.  Why didn't they put a phone (camera, gps, other....) in it ? - why would you possibly want a phone in it ?  You're not going to hold that up to the side of your face are you ?  Similarly with the camera, though I concede that a front facing one would be useful as a webcam, but you are not going to use it to take holiday (or Facebook) snaps.  As for other complaints about the lack of peripherals, again, you are missing the point.  Plug your peripherals into your PC (or Mac), not into the iPad that's lying on your knees as you are lounging on the sofa.


The point of the Google OS and the iPad (and other products being offered and developed by these companies) is that computing should be delivered to the masses as appliances.  And this is precisely why the technical community, who are the ones commenting and writing all the articles on these things, don't get it.  Technical people look at these things and see all the stuff that they can't do with them, but fail to realise that non-technical people don't want to do this stuff - they just want a device that works without them having to worry about things like viruses and backups.
Google's problem in this is that their vision is aimed at the techie community, which largely don't get or want that vision.  They are appealing to the same market as Apple, but contrasting it with "Hey, we're free and open, don't buy that proprietary, locked down fanbois kit".  Trouble is, the only people that care about free and open are the geeks, and they want full-featured computers, not appliances.
So, my money is (metaphorically anyway) on Apple as they are aiming at the non-technical customer and all the criticisms of their approach that are levelled at them by the techie crowd are actually strengths in their target market.

Take a good look next time you pass an Apple shop - look at how rammo it is with ordinary people oohing and aahing over the lovely shiny gadgets.  You slap an iPad in front of these people and they will lap it up.

Friday, 29 January 2010

Managing Roaming Profile Size

Many of my clients have problems with their roaming profiles getting too large.
As mentioned in a previous post, this is mainly due to badly written software storing files in the roaming, rather than local, part of the user profile.  In addition to slowing down logins, there is a hardcoded limit of 90MB on roaming profiles so it is important to keep this nice and trim.
To combat this, I have written a script which can be run periodically (weekly say, overnight when the users are logged out) to clear out all the cruft that, left alone, will cause the profile to break.
Currently this script removes the following files:
  • Adobe update files
  • Real update files
  • Java cache files
  • Apple iPod & iPhone firmware updates
Hopefully this may prove useful to others, just make sure to set the PROFILE_ROOT variable to point to the location of the roaming profiles on the server.
If you want to see what it will do before, then run with the -test switch which will just output what it intends to remove, but wont actually delete anything
@echo off
REM cleanup_profiles.cmd
REM v 1.0
REM This file removes any unnecessary files from roaming profiles
REM files removed:
REM     Adobe update files
REM     Real update files
REM     java cache files
REM     ipod & iphone firmware updates
REM by Jon Reeves
REM run with -test switch to just show what would be done, but not
REM actually delete any files
REM cleanup_profiles -test
REM ***** MAKE SURE to set the PROFILE_ROOT variable *****
SET PROFILE_ROOT=E:\Shared\Profiles
REM ******************************************************
set TESTRUN=FALSE
if "%1" == "-test" set TESTRUN=TRUE
SET DELETION_FILE=%TEMP%\profcleanupdeletion.txt
REM list folders to be deleted
for /F "delims=" %%u in ('dir %PROFILE_ROOT% /B /A:D') DO dir /s /b /a:d "%PROFILE_ROOT%\%%u\Application Data\Adobe" | findstr Updater >> %DELETION_FILE%
for /F "delims=" %%u in ('dir %PROFILE_ROOT% /B /A:D') DO dir /s /b /a:d "%PROFILE_ROOT%\%%u\Application Data\Real" | findstr Update >> %DELETION_FILE%
for /F "delims=" %%u in ('dir %PROFILE_ROOT% /B /A:D') DO echo "%PROFILE_ROOT%\%%u\Application Data\Sun\Java\Deployment\cache" >> %DELETION_FILE%
for /F "delims=" %%u in ('dir %PROFILE_ROOT% /B /A:D') DO dir /b /s "%PROFILE_ROOT%\%%u\Application Data\Apple Computer\iTunes\iPhone Software Updates" | findstr .ipsw >> %DELETION_FILE%
for /F "delims=" %%u in ('dir %PROFILE_ROOT% /B /A:D') DO dir /b /s "%PROFILE_ROOT%\%%u\Application Data\Apple Computer\iTunes\iPod Software Updates" | findstr .ipsw >> %DELETION_FILE%
REM do the actual deletion
if %TESTRUN% EQU TRUE goto TESTRUN
REM delete directories
for /F "delims=" %%d in (%DELETION_FILE%) DO rmdir /S /Q %%d
REM delete files
for /F "delims=" %%f in (%DELETION_FILE%) DO del /F /Q %%f
goto CLEANUP
:TESTRUN
echo Test run completed, no files have been deleted
notepad %DELETION_FILE%
:CLEANUP
REM clean up temp files
del %DELETION_FILE%
set TESTRUN=

Saturday, 23 January 2010

How to get SIP working through Cisco 837 router

At last!
Finally I have got a SIP softphone working through my firewall.
I spent hours and hours trying different inspection rules and nat traversal stuff and eventually gave up, but after waking up obscenely early this morning I decided to give it a quick googling.
Five minutes later it was working - seems all I had to do was disable the SIP ALG on my Cisco 837 router:
no ip nat service sip udp port 5060
And it works !
Of course now I find that sound doesnt work in Ekiga (grumble, grumble), but Twinkle works perfectly.