Friday, February 26, 2016

All the Special Key Combinations that Change Your Mac's Startup

From http://lifehacker.com/all-the-special-key-combinations-that-change-your-macs-1761327018
  • Shift: Starts your Mac in safe mode. This helps you troubleshoot because it only loads the minimum necessary kernel extensions at boot then disables startup items, user-installed fonts, font caches, kernel caches, and other system cache files. Safe mode also runs a file system check automatically, which should help with troubleshooting. 
  • Option: This loads up the startup manager where you can pick between different hard drives or discs to boot into. If you need to boot from a hard drive different than your primary one, or you’re booting into Boot Camp, this is the key you push. 
  •  C: Boots from a bootable CD, DVD, or USB. This is useful when you’re installing a new operating system. 
  • D or Option+D: Starts the Apple Hardware Test on pre-2013 Macs or Apple Diagnostics on newer Macs. Both are meant to help troubleshoot hardware issues. N or 
  • Option+N: Starts up from a Netboot server. Most average users will never need to use this as it’s meant for running OS X off a network instead of a hard drive or disc drive. 
  • Command+R: Starts up in Recovery mode. If you have problems with your hard drive, OS X Recovery allows you to restore your Mac from a backup, verify and repair your disc, check your internet connection, or reinstall OS X. 
  • Command+Option+R: Starts up the internet version of Recovery mode, which works the same as regular Recovery mode, but is online. 
  • Command+Option+P+R: This resets the NVRAM. NVRAM stores information about speaker volume, screen resolution, startup disk selection, and recent kernel panic information. If you’re having issues with sound or video, it’s usually a good idea to reset the NVRAM before panicking. 
  • Command+S: Starts up in single-user mode. This is meant mostly for developers and IT as a means to troubleshoot startup issues and basically drops you into the command line where you can run tests without worrying about the GUI in OS X. 
  •  Command+V: Starts up in verbose mode. Verbose mode is similar to single-user mode but is meant more as a way to watch what a computer is doing to help with troubleshooting. 
  • T: Starts your Mac in target disk mode. This is a useful way to share files between two Macs when one of them is broken or the display isn’t working. 
  • Eject button, F12, mouse button, or trackpad button: Force eject an optical disk.

Edit site permissions in Firefox

It used to be simple to edit site permission sin Firefox, you only needed to click the icons on the left of the awesome bar and you would see the connection security (encrypted/unsecured) and the permissions pane with the switches to allow as default, permit or deny.
Currently in Firefox 44.0.2, the Permissions pane only shows you the current permission of the site, not allowing you to edit them. To edit the permissions of the current site you have to:
  1. Click on the icons in the left of the awesome bar, 
  2. Click on the arrow of the panel describing the connections security

  3. Click on the Button "More Information"

  4. Click on the tab "Permissions"
  5. Now you can edit the website permissions
To See and edit permissions to all websites, including the default permissions, you can type
about:permissions in the awesome bar.

Wednesday, February 10, 2016

Dump Table date to SQL using Microsoft SQL Server

You can export the data in a table or DB into a SQL query using Microsoft SQL server Management studio by doing:
right click on the DB -> Tasks -> Generate Scripts. On the wizard step titled "Set Scripting Options" choose "Advanced" and modify the "Types of data to script" option to "Data"

This question was answered in http://serverfault.com/questions/147638/dump-microsoft-sql-server-database-to-an-sql-script

Tuesday, February 02, 2016

Install Disk cleanup in windows 2008 r2

The site basics.net have the instructions how to install the disk cleanup nicely (the default Microsoft way is crap because you end up withi loads of stuff installed in the system), the article with the instructions is http://www.basics.net/2013/02/25/win-server-2008-r2-how-to-enable-the-disk-cleanup-utility/
Copy 2 files to specific system folders and you can immediately use the tool:

Copy Cleanmgr.exe to %systemroot%\System32.
Copy Cleanmgr.exe.mui to %systemroot%\System32\en-US.
The 2 files are located in
- C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr_31bf3856ad364e35_6.1.7600.16385_none_c9392808773cd7da\cleanmgr.exe
- C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr.resources_31bf3856ad364e35_6.1.7600.16385_en-us_b9cb6194b257cc63\cleanmgr.exe.mui

You can simply run this as administrator:
copy C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr_31bf3856ad364e35_6.1.7600.16385_none_c9392808773cd7da\cleanmgr.exe %systemroot%\System32
copy C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr.resources_31bf3856ad364e35_6.1.7600.16385_en-us_b9cb6194b257cc63\cleanmgr.exe.mui %systemroot%\System32\en-US