Thursday, November 3, 2016
Reset PRAM in Mac OS without holding keys at startup
This command is the functional equivalent of holding down command-option-p-r at start up. It resets the machine's PRAM.
% sudo nvram boot-args='-p -r'
My 2009 Mac mini was having problems starting up (light on but no ding or gray apple screen). I have not seen this startup problem since resetting the PRAM. Hopefully this fixes the problem.
Wednesday, September 7, 2016
Setting up IE VM images in VirtualBox on Mac
Get images from here:
https://developer.microsoft.com/en-us/microsoft-edge/tools/vms/
Extract the zip File
VirtualBox > File > Import Appliance , select the .ovf file
Settings > System > Base Memory > 2048 MB
2 CPU
Snapshot now, so it's easy to restore when the license expires. If you do this later, snapshot restore may not be sufficient to relicense the install.
In WIN7
Network Location: Home
Virtual Box > Devices > Install Guest Additions CD
Virtual Box> Devices > Shared Clipboard > Bidirectional
Virtual Box> Devices > Drag and Drop > Bidirectional
WIN7 > Explorer > Run Guest Additions.exe , will restart
WIN7 Edit C:\Windows\System32\drivers\etc\hosts
add entry for host os:
ifconfig to get the Default Gateway IP
Test ping
Test IE
Friday, June 17, 2016
Update spotlight index
http://osxdaily.com/2012/02/02/reindex-spotlight-from-the-command-line/
sudo mdutil -E /
Change the UID of files
Occasionally, the Centrify client on my corporate mac changes the UID associated with my username. This breaks nearly everthing. Solution is to do the following as root:
identify the old uid with %ls -ln
identify the new uid with %id -u
% find / -user -exec chown -vh {} ;
Tuesday, July 21, 2015
Setting up IntelliJ IDEA to run Spring Applications with Jetty
- I needed Servlet 3.0 features (like config through ServletContainerInitializer interface), but unfortunately Gradle's Jetty plugin (as of v2.4) uses Jetty 6, so it doesn't support Servlet 3.0. So I'm not bothering.
- Instead, I used the third party plugin gretty: http://akhikhl.github.io/gretty-doc/Getting-started.html
- Had problems using gretty with the IDEA's Default Gradle Wrapper (gradle 1.8):
Error:Unable to load class 'org.codehaus.groovy.runtime.typehandling.ShortTypeHandling'.
Possible causes for this unexpected error include:
Re-download dependencies and sync project (requires network)
The state of a Gradle build process (daemon) may be corrupt. Stopping all Gradle daemons may solve this problem.
Stop Gradle build processes (requires restart)
In the case of corrupt Gradle processes, you can also try closing the IDE and then killing all Java processes.
So instead I switched to using Local Gradle Distribution (2.4).
Use gradle appStart to start the server.
Use gradle appStop to stop the server.
- I needed Servlet 3.0 features (like config through ServletContainerInitializer interface), but unfortunately Gradle's Jetty plugin (as of v2.4) uses Jetty 6, so it doesn't support Servlet 3.0. So I'm not bothering.
- Instead, I used the third party plugin gretty: http://akhikhl.github.io/gretty-doc/Getting-started.html
- Had problems using gretty with the IDEA's Default Gradle Wrapper (gradle 1.8):
Error:Unable to load class 'org.codehaus.groovy.runtime.typehandling.ShortTypeHandling'.
Possible causes for this unexpected error include:
- Gradle's dependency cache may be corrupt (this sometimes occurs after a network connection timeout.)
Re-download dependencies and sync project (requires network)
In the case of corrupt Gradle processes, you can also try closing the IDE and then killing all Java processes.
So instead I switched to using Local Gradle Distribution (2.4).
Use gradle appStart to start the server.
Use gradle appStop to stop the server.
Monday, July 20, 2015
IntelliJ 14 CE not updating Maven Repository Indices
Was seeing errors when trying to update Maven repositories in IntelliJ 14 CE
Preferences / Build, Execution, Deployment > Build Tools > Maven > Repositories
All of the Remote Repositories where showing 'Error'.
Hitting Update worked occasionally (like maybe 1/20 times)
Saw this in the Event Log
10:14:25 AM Unindexed remote maven repositories found. Disable...
The following repositories used in your gradle projects were not indexed yet:
http://download.java.net/maven/2
http://maven.springframework.org/milestone
http://maven.springframework.org/release
If you want to use dependency completion for these repositories artifacts,
Open Repositories List, select required repositories and press "Update" button (show balloon)
Also saw Exceptions in idea.log (Help / Show Log in Finder)
Tried alternative WI-FI and Ethernet connections, including the hotspot on my phone. No change.
On ths advice of these Threads:
https://youtrack.jetbrains.com/issue/IDEA-102693
https://youtrack.jetbrains.com/issue/IDEA-138029
I removed the -Xmx512m Setting under Preferences / Build, Execution, Deployment > Build Tools > Maven > Importing > VM options for Importer
Intially, this seemed to work ... but alas I think it was a coincidence. It worked fine on the first attempt to update repo1.maven.org, but failed on the others...and ultimately failed when retrying repo1.maven.org.
Then Tried changing the Maven Importing JRE:
Build, Execution, Deployment > Build Tools > Maven > Importing > JDK for Importer
from the Default (Use Internal JRE (1.6) ) to the JDK 1.8 I had installed.
Again, this seemed to work initially....but failed on second attempt.
Then I tried killing the RemoteMavenServer (java process found using ps aux | grep maven). This also made the first download attempt work, but subsequent downloads failed. I suspect changing the -Xmx and JRE in the above attempts was restarting Java ..... and triggering the same effect as killing the maven process. The problem seems to be in the interaction between IDEA and the external maven process.
For now, my solution is to kill any existing RemoteMavenServer process before clicking the 'Update' button. An easy way to do this it to make some trivial change in VM Options for Importer .... which causes IDEA to restart the external maven process.
This problem is well characterized here:
https://youtrack.jetbrains.com/issue/IDEA-138029
Hope JetBrains fixes this one soon.
Preferences / Build, Execution, Deployment > Build Tools > Maven > Repositories
All of the Remote Repositories where showing 'Error'.
Hitting Update worked occasionally (like maybe 1/20 times)
Saw this in the Event Log
10:14:25 AM Unindexed remote maven repositories found. Disable...
The following repositories used in your gradle projects were not indexed yet:
http://download.java.net/maven/2
http://maven.springframework.org/milestone
http://maven.springframework.org/release
If you want to use dependency completion for these repositories artifacts,
Open Repositories List, select required repositories and press "Update" button (show balloon)
Also saw Exceptions in idea.log (Help / Show Log in Finder)
Tried alternative WI-FI and Ethernet connections, including the hotspot on my phone. No change.
On ths advice of these Threads:
https://youtrack.jetbrains.com/issue/IDEA-102693
https://youtrack.jetbrains.com/issue/IDEA-138029
I removed the -Xmx512m Setting under Preferences / Build, Execution, Deployment > Build Tools > Maven > Importing > VM options for Importer
Intially, this seemed to work ... but alas I think it was a coincidence. It worked fine on the first attempt to update repo1.maven.org, but failed on the others...and ultimately failed when retrying repo1.maven.org.
Then Tried changing the Maven Importing JRE:
Build, Execution, Deployment > Build Tools > Maven > Importing > JDK for Importer
from the Default (Use Internal JRE (1.6) ) to the JDK 1.8 I had installed.
Again, this seemed to work initially....but failed on second attempt.
Then I tried killing the RemoteMavenServer (java process found using ps aux | grep maven). This also made the first download attempt work, but subsequent downloads failed. I suspect changing the -Xmx and JRE in the above attempts was restarting Java ..... and triggering the same effect as killing the maven process. The problem seems to be in the interaction between IDEA and the external maven process.
For now, my solution is to kill any existing RemoteMavenServer process before clicking the 'Update' button. An easy way to do this it to make some trivial change in VM Options for Importer .... which causes IDEA to restart the external maven process.
This problem is well characterized here:
https://youtrack.jetbrains.com/issue/IDEA-138029
Hope JetBrains fixes this one soon.
Monday, July 6, 2015
IntelliJ Gradle not resolving dependencies
Followed the typical process of setting up a simple Gradle project in IntelliJ IDEA 14 ....but dependencies were not resolving. Upon hitting the refresh button, each of the gradle dependencies were underlined red....no useful feedback in logs or console.
I eventually figured out the problem: Intellij was configured for Gradle offline mode.
Preferences >> Build, Execution & Deployment > Build Tools > Gradle >> Offline Work
Global Gradle Settings was set to 'Offline Work'. I have no idea why, may have been due to a sketchy WI-FI connection I was using.
After unchecking the box and refreshing the Gradle project, I'm back on track.
I found it very useful to download and install Gradle for the command line (using gvm) so I could test Gradle independent of IntelliJ. I had no problems using command line gradle to download dependencies....telling me the problem was with IDEA.
It was also helpful to run Gradle tasks (like compileJavaTest) directly using IntelliJ. While, 'Refresh' produces no useful console output, running Gradle tasks do.... and in this case the error told me the problem was 'Offline Mode'.
I eventually figured out the problem: Intellij was configured for Gradle offline mode.
Preferences >> Build, Execution & Deployment > Build Tools > Gradle >> Offline Work
Global Gradle Settings was set to 'Offline Work'. I have no idea why, may have been due to a sketchy WI-FI connection I was using.
After unchecking the box and refreshing the Gradle project, I'm back on track.
I found it very useful to download and install Gradle for the command line (using gvm) so I could test Gradle independent of IntelliJ. I had no problems using command line gradle to download dependencies....telling me the problem was with IDEA.
It was also helpful to run Gradle tasks (like compileJavaTest) directly using IntelliJ. While, 'Refresh' produces no useful console output, running Gradle tasks do.... and in this case the error told me the problem was 'Offline Mode'.
Friday, February 20, 2015
Maven 3.2.5 not connecting to https:// repositories
At work, Maven was failing to connect to https://repo1.maven.org/maven2. I was getting a 'Connection Reset' error. Don't know why. Seemed to be a problem with https, proxy corp network?
I fixed this link in updating my ~/.m2/settings.xml. I changed all the urls to http.
http://stackoverflow.com/questions/25911623/problems-using-maven-and-ssl-behind-proxy
Why can't this stuff just work?
-Matt
I fixed this link in updating my ~/.m2/settings.xml. I changed all the urls to http.
http://stackoverflow.com/questions/25911623/problems-using-maven-and-ssl-behind-proxy
Why can't this stuff just work?
-Matt
Friday, November 21, 2014
Connect to Beaglebone Black over Debug Serial Header / Windows 7
- Install BB Drivers
- Install FTDI Virtual Com port drivers (http://www.ftdichip.com/Drivers/VCP.htm)
- Connect the FTDI friend (http://www.adafruit.com/product/284) to the 6-pin debug serial header on the BB, chip facing out.
- Power BB
- Connect USB from FTDI Friend to PC.
- Use Device Manager to determine COM port.
- Use Putty to connect (COMX, Speed = 115200, Data Bits = 8, Stop Bits = 1, Parity = None, Flow Control = None)
- Hit return, look for login prompt.
- Connect Ethernet to network
- ifconfig to determine IP address
- SSH from PC to IP address....
Friday, June 27, 2014
Restore Reminder popup in Outlook 2010
http://www.codingeverything.com/2013/05/making-sure-outlook-calendar-reminders.html#StepNumberFive
Here's the formatted script
'Declare Functions From User32 Library
Private Declare PtrSafe Function FindWindowA Lib "user32" _
(ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Private Declare PtrSafe Function SetWindowPos Lib "user32" ( _
ByVal hwnd As Long, ByVal hWndInsertAfter As Long, _
ByVal X As Long, ByVal Y As Long, ByVal cx As Long, _
ByVal cy As Long, ByVal wFlags As Long) As Long
'Declare Constants
Private Const SWP_NOSIZE = &H1
Private Const SWP_NOMOVE = &H2
Private Const FLAGS As Long = SWP_NOMOVE Or SWP_NOSIZE
Private Const HWND_TOPMOST = -1
'Finds Reminder Window and Brings to TopMost position
Private Sub Application_Reminder(ByVal Item As Object)
Dim ReminderWindowHWnd As Variant
Dim cnt As Long
On Error Resume Next
cnt = 1
Do Until (cnt > 20 Or ReminderWindowHWnd <> 0)
ReminderWindowHWnd = FindWindowA(vbNullString, cnt & " Reminder(s)")
cnt = cnt + 1
Loop
'bring reminder window to front
SetWindowPos ReminderWindowHWnd, HWND_TOPMOST, 0, 0, 0, 0, FLAGS
End Sub
Sunday, May 25, 2014
Installing SSD
Roughly following this guide:
http://forums.crucial.com/t5/Solid-State-Drives-SSD-Knowledge/How-to-clone-your-old-hard-drive-to-your-SSD-Mac/ta-p/112072
Created a bootable 'Install OSX' USB key.
http://lifehacker.com/how-to-create-an-os-x-mavericks-usb-installation-drive-1450280026
http://forums.macrumors.com/showpost.php?p=18081307&postcount=3
Put the SSD in a USB enclusure and attach.
Boot to the USB by selecting it in System Preferences >> Startup Disk , then restarting.
http://forums.crucial.com/t5/Solid-State-Drives-SSD-Knowledge/How-to-clone-your-old-hard-drive-to-your-SSD-Mac/ta-p/112072
From the startup USB, run Disk Utility
- Create a single Partition on the SSD formatted as Mac OS Extended (Journaled)
- Use the Restore function to copy the main partition from the HDD to the partition on the SSD. (Took 10 hours!) It was not possible to select an entire Disk as the source or Destination. I'll have to verify the Recovery Partition was copied over later.
Verify successful transfer of 'hidden' partitions (Including the Recovery Partition)
http://macs.about.com/od/usingyourmac/qt/Enable-Disk-Utilitys-Debug-Menu.htm
Yes, the EFI and Recovery Partitions are there. Strangely, I didn't need to enable the DEBUG menu to see them.
Enable TRIM
http://www.nick-p.info/enabling-trim-on-a-new-ssd-on-os-x-mavericks/
About This Mac > More Info > System Report. Then, scroll to the SATA/SATA Express section, and select your SSD. You should see a section called TRIM and the answer should be YES

Installed DriveDX to check Disk Health. Everything OK and Good, but why is my SSD Lifetime already at 99.0%?
Checked Samsung for Firmware updates. Compared revision to what I see in System Report. It looks like I've got the latest: EXT0BB6Q
http://www.samsung.com/global/business/semiconductor/samsungssd/downloads.html
Initial Observations:
Startup is faster. Seems to take just as much time until the Desktop appears ... but once the Desktop is there ... everything is functional....no more waiting for pinwheels.
The Machine does seem more responsive. So far so good. Time to turn it over to QA for the Minecraft test.
Useful links:
http://osxdaily.com/2013/02/06/how-to-run-gui-apps-as-root-in-mac-os-x/
Securely erase an SSD
https://discussions.apple.com/docs/DOC-5521
http://forums.crucial.com/t5/Solid-State-Drives-SSD-Knowledge/How-to-clone-your-old-hard-drive-to-your-SSD-Mac/ta-p/112072
Created a bootable 'Install OSX' USB key.
http://lifehacker.com/how-to-create-an-os-x-mavericks-usb-installation-drive-1450280026
http://forums.macrumors.com/showpost.php?p=18081307&postcount=3
Put the SSD in a USB enclusure and attach.
Boot to the USB by selecting it in System Preferences >> Startup Disk , then restarting.
http://forums.crucial.com/t5/Solid-State-Drives-SSD-Knowledge/How-to-clone-your-old-hard-drive-to-your-SSD-Mac/ta-p/112072
From the startup USB, run Disk Utility
- Create a single Partition on the SSD formatted as Mac OS Extended (Journaled)
- Use the Restore function to copy the main partition from the HDD to the partition on the SSD. (Took 10 hours!) It was not possible to select an entire Disk as the source or Destination. I'll have to verify the Recovery Partition was copied over later.
Verify successful transfer of 'hidden' partitions (Including the Recovery Partition)
http://macs.about.com/od/usingyourmac/qt/Enable-Disk-Utilitys-Debug-Menu.htm
Yes, the EFI and Recovery Partitions are there. Strangely, I didn't need to enable the DEBUG menu to see them.
Enable TRIM
http://www.nick-p.info/enabling-trim-on-a-new-ssd-on-os-x-mavericks/
About This Mac > More Info > System Report. Then, scroll to the SATA/SATA Express section, and select your SSD. You should see a section called TRIM and the answer should be YES
Installed DriveDX to check Disk Health. Everything OK and Good, but why is my SSD Lifetime already at 99.0%?
Checked Samsung for Firmware updates. Compared revision to what I see in System Report. It looks like I've got the latest: EXT0BB6Q
http://www.samsung.com/global/business/semiconductor/samsungssd/downloads.html
Initial Observations:
Startup is faster. Seems to take just as much time until the Desktop appears ... but once the Desktop is there ... everything is functional....no more waiting for pinwheels.
The Machine does seem more responsive. So far so good. Time to turn it over to QA for the Minecraft test.
Useful links:
http://osxdaily.com/2013/02/06/how-to-run-gui-apps-as-root-in-mac-os-x/
Securely erase an SSD
https://discussions.apple.com/docs/DOC-5521
Installing 8GB Memory in my Mac Mini (Early 2009)
Added 8GB of Corsair memory to my Mac Mini (Early 2009) MB463LL/A
I could not find official documentation that the firmware would support 8GB, but many users reported doing this successfully. I verified that my Mac had the latest Firmware installed. Installed the Memory. Seems to be working fine after many hours of use.
I wanted to test the memory, but I can't figure out how to boot the Mac into the Diagnostic Mode described here:
http://support.apple.com/kb/PH11342
Holding down D while restarting doesn't seem to work. I think it's because I'm using a Non-Apple wireless keyboard. I'm betting the keyboard isn't functional when the BIOS is looking for startup keys.
I also can't seem to boot from a USB key I made for running MEMTEST86+ for similar reason. Holding down Option (alt) doesn't work for entering Startup Manager.
http://support.apple.com/kb/HT1310
TODO: Obtain a Wired keyboard and try again.
Notes: Keyboard mappings: Option = Alt, Command = Windows key
I could not find official documentation that the firmware would support 8GB, but many users reported doing this successfully. I verified that my Mac had the latest Firmware installed. Installed the Memory. Seems to be working fine after many hours of use.
I wanted to test the memory, but I can't figure out how to boot the Mac into the Diagnostic Mode described here:
http://support.apple.com/kb/PH11342
Holding down D while restarting doesn't seem to work. I think it's because I'm using a Non-Apple wireless keyboard. I'm betting the keyboard isn't functional when the BIOS is looking for startup keys.
I also can't seem to boot from a USB key I made for running MEMTEST86+ for similar reason. Holding down Option (alt) doesn't work for entering Startup Manager.
http://support.apple.com/kb/HT1310
TODO: Obtain a Wired keyboard and try again.
Notes: Keyboard mappings: Option = Alt, Command = Windows key
Saturday, May 24, 2014
My rsync backup command
sudo rsync -avHS --filter="merge /Users/backup_rsync_filters" --delete-excluded --delete --progress '/Users/' '/Volumes/Vantec/Users/'
contents of backup_rsync_filters
#BEWARE OF TRAILING WHITESPACE.....rsync does not trim lines
#Force descent into Virtual Box, but exclude everything else in Library (*took me a while to figure this out
include /mullermw/Library/ include /mullermw/Library/Virtual Box/
exclude /*/Library/
exclude /*/Downloads/
exclude /*/Movies/
exclude .Trash/
contents of backup_rsync_filters
#BEWARE OF TRAILING WHITESPACE.....rsync does not trim lines
#Force descent into Virtual Box, but exclude everything else in Library (*took me a while to figure this out
include /mullermw/Library/ include /mullermw/Library/Virtual Box/
exclude /*/Library/
exclude /*/Downloads/
exclude /*/Movies/
exclude .Trash/
Tuesday, November 26, 2013
Netgear Nighthawk AC1900 R7000 setup
Some installation notes for my new Router:
Updated Firmware to V1.0.1.22_1.0.15
Put the Router in Access Point Mode. See Manual Section: 'Use the Router as Wireless Access Point'.
Note: After setup, the Router's web-app http://www.routerlogin.com no longer functioned. I was able to connect through http://r7000 or just look up the IP in the DSL Modems-Router .
This router kicks ass!
-Matt
Updated Firmware to V1.0.1.22_1.0.15
Put the Router in Access Point Mode. See Manual Section: 'Use the Router as Wireless Access Point'.
Note: After setup, the Router's web-app http://www.routerlogin.com no longer functioned. I was able to connect through http://r7000 or just look up the IP in the DSL Modems-Router .
This router kicks ass!
-Matt
Friday, November 8, 2013
Eclipse Subversive Reminders
I always forget these:
Override & Update : Replaces Local with Remote
Override & Commit: Replaces Remote with Local
Override & Update : Replaces Local with Remote
Override & Commit: Replaces Remote with Local
Saturday, October 19, 2013
Transfer Keeper Password Vault to new Device
Very easy with iExplorer:
http://lifehacker.com/5891964/can-i-transfer-app-data-and-game-saves-from-my-iphone-to-a-new-ipad
Just copy the Documents/keeper.sql file to the new device.
Might not work so well if the app versions are different...but this worked for me...
Saved me alot of time.
This is also a cheap and easy way to backup your vault and maintain encryption.
-Matt
Monday, September 30, 2013
How to Add a Clinical Question in Orchard AP
- Create a 'Test' item
- File >> Table Setup >> Tests >> New
- Enter Test name, Abbreviation
- Keep Enterability as Enterable as numeric and text/choice list (Keep this setting even if you want the question to have an enumerated set of answers, the answer choices will be set later.)
- Set Location (I set it to Veracyte, but it probably doesn't matter)
- Save
- Create a 'Clinical Information' item
- File >> Table Setup >> Clinical Information
- Enter the Question. Note, questions are asked in Alphanumeric order. You can prefix a number to control question order.
- Select the 'Tied Test' that you created in step 1.
- Set the 'Answer Type'. Use 'Pre-Defined Text' for a question with Enumerated Answers.
- Set the Valid Answers (if applicable)
- Save
- Attach the 'Clinical Information' to the 'Specimen'
- File >> Table Setup >> Specimens
- Click the Specimen you want to attach the Clinical Information To
- Click 'Clinical Info'
- Find the Clinical Information you created in step 2.
- Ctrl-click it to add it to the set of Questions
- OK
- Save
- Test your new Question
Subscribe to:
Posts (Atom)
