Some pictures are worth a thousand words.
From: http://fermi.mycloudnas.com/2011/03/rebuild-nas/passwd/.
Coffee | Coding | Computers | Church | What does it all mean?
Some pictures are worth a thousand words.
From: http://fermi.mycloudnas.com/2011/03/rebuild-nas/passwd/.
The really fasted XML editor I've ever used is XMLMarker which loads a 5MB file in a fraction of a second. When editing, it shows the XML simultaneously in tree, text and 'Data Grid' views which is quite impressive as are a couple of its other features:
But I'm often doing RegEx
search and replace, which XML Marker doesn't do, and often editing text as well as xml. Notepad++ is quite speedy and can do regexes, but Sublime Text 2 does regex search and replace much better: it does live highlighting of what its found as you type, so you can 'debug' your regexing on the fly.
Everyone wants xml pretty printing (well, re-indenting), which for Sublime Text 2 is done by first installing the WBond.net package manager and then installing the 'Indent XML' package. Package Management in Sublime Text is a bit command-liney, so do read Mr. Bond's instructions.
Run this query, or remove the comments to actually create a stored proc.
Note that SQL pre-2008 requires a field to be commented out of the query, as noted inline.
/* --Create Procedure WhoLock --AS if object_id('tempdb..#locksummary') is not null Drop table #locksummary if object_id('tempdb..#lock') is not null Drop table #lock create table #lock ( spid int, dbid int, objId int, indId int, Type char(4), resource nchar(32), Mode char(8), status char(6)) Insert into #lock exec sp_lock if object_id('tempdb..#who') is not null Drop table #who create table #who ( spid int, ecid int, status char(30), loginame char(128), hostname char(128), blk char(5), dbname char(128), cmd char(16) -- , request_id INT --Remove this line for SQL 2005 or earlier -- ) Insert into #who exec sp_who Print '-----------------------------------------' Print 'Lock Summary for ' + @@servername + ' (excluding tempdb):' Print '-----------------------------------------' + Char(10) Select left(loginame, 28) as loginame, left(db_name(dbid),128) as DB, left(object_name(objID),30) as object, max(mode) as [ToLevel], Count(*) as [How Many], Max(Case When mode= 'X' Then cmd Else null End) as [Xclusive lock for command], l.spid, hostname into #LockSummary from #lock l join #who w on l.spid= w.spid where dbID != db_id('tempdb') and l.status='GRANT' group by dbID, objID, l.spid, hostname, loginame Select * from #LockSummary order by [ToLevel] Desc, [How Many] Desc, loginame, DB, object Print '--------' Print 'Who is blocking:' Print '--------' + char(10) SELECT p.spid ,convert(char(12), d.name) db_name , program_name , p.loginame , convert(char(12), hostname) hostname , cmd , p.status , p.blocked , login_time , last_batch , p.spid FROM master..sysprocesses p JOIN master..sysdatabases d ON p.dbid = d.dbid WHERE EXISTS ( SELECT 1 FROM master..sysprocesses p2 WHERE p2.blocked = p.spid ) Print '--------' Print 'Details:' Print '--------' + char(10) Select left(loginame, 30) as loginame, l.spid, left(db_name(dbid),15) as DB, left(object_name(objID),40) as object, mode , blk, l.status from #lock l join #who w on l.spid= w.spid where dbID != db_id('tempdb') and blk <>0 Order by mode desc, blk, loginame, dbID, objID, l.status
Although this is a bare metal approach to investigating sql contention, the query does show you actual login names, so it enables you to join up technical issues with affected/affecting customers.
— updated after BootCamp 5 release June 2013 —
Where can you get a direct download of Windows drivers for Macs if BootCamp is stuck, and says 'could not continue' or you have some other problem downloading the drivers?
The brute force solution: it’s a darned large download, so physically take your machine to somewhere with a very fast internet connection that can download 600MB – 1GB in a couple of minutes. There, you’re done. Especially if you have a laptop, this would be the simplest solution - even take it to an Apple Store.
For the rest of us:
Then, search for your ModelIdentifier in the table below. Click the link to get the download package. Be patient as they are 600MB to over 1GB. It will be much simpler if you do the download in OS X, because OS X can open the downloaded file and also open the dmg file inside it.
Still in Mac OS X, once your pkg is downloaded, double click it and install to a folder on your hard drive so you know where to find it. During the Installation, click the "Change Location" option so that you can choose where it gets installed.
If you must do the download in Windows instead OS X, it's harder. You will need the help on http://www.cafe-encounter.net/p860/opening-a-bootcamp-driver-download-on-windows-7-or-8-with-7-zip to open the pkg file and the dmg file inside it.
Most of these driver downloads work for both Windows 7 and Windows 8. Windows 8 on 32-bit is not officially supported, but almost everything seems to works on fine on not-officially supported models: the only specific shortcoming I'm aware of is that the screen brightness buttons don't work on all models.
Model Identifier | Size & driver release date | Direct Download Link |
---|---|---|
Macmini6,1 Macmini6,2 MacBookPro10,2 iMac13,1 iMac13,2 |
438MB, 3 Dec 2012 | http://swcdn.apple.com/content/downloads/54/18/041-8805/9tglhtxadqtnrro79rsdy4f0mkgu7wg6or/BootCampESD.pkg |
MacBookPro9,1 MacBookPro9,2 |
1,058MB, 15 June 2012 | http://swcdn.apple.com/content/downloads/11/05/041-0925/g27es04pw9re5ggrfp3vuf8ew6r53asfz8/BootCampESD.pkg |
MacBookPro10,1 MacBookAir5,1 MacBookAir5,2 |
942MB, 15 June 2012 | hhttp://swcdn.apple.com/content/downloads/55/51/041-3891/se4uhpqng48t842cdsosqh28lft54fmswl/BootCampESD.pkg |
MacBookAir4,1 MacBookAir4,2 Macmini5,1 Macmini5,2 Macmini5,3 |
676MB, 23 May 2012 | hhttp://swcdn.apple.com/content/downloads/32/33/041-2303/W5jKtsQhhMgMXs3TKhPDqLXrpXyY2HdXMN/BootCampESD.pkg |
MacBook2,1 MacBook3,1 MacBook4,1 MacBook5,1 MacBook5,2 MacBook5,3 MacBook6,1 MacBook7,1 MacBookAir1,1 MacBookAir2,1 MacBookAir3,1 MacBookAir3,2 MacBookPro2,1 MacBookPro2,2 MacBookPro3,1 MacBookPro4,1 MacBookPro5,1 MacBookPro5,2 MacBookPro5,3 MacBookPro5,4 MacBookPro5,5 MacBookPro6,1 MacBookPro6,2 MacBookPro7,1 MacBookPro8,1 MacBookPro8,2 MacBookPro8,3 MacPro1,1 MacPro2,1 MacPro3,1 MacPro4,1 MacPro5,1 Macmini2,1 Macmini3,1 Macmini4,1 iMac5,1 iMac6,1 iMac7,1 iMac8,1 iMac9,1 iMac10,1 iMac11,1 iMac11,2 iMac11,3 iMac12,1 iMac12,2 |
632MB, 23 May 2012 | http://swcdn.apple.com/content/downloads/33/54/041-2011/pRtCDYcWShMLxFggy3TzFzmfnnWQNFQBfJ/BootCampESD.pkg |
If you're struggling to find your ModelIdentifier then you want the brilliant page at everymac.com which can tell you what model Mac you have based on serial number. On the result page after you submit, look carefully and you'll the ModelIdentifier.
If you're still stuck, then:
See BootCampESD.pkg download instructions for references and for the DIY instructions to work out these links yourself.