Skip to main content

Posts

Showing posts from October, 2017

MAC OS - Change Screenshots Location

If you want to take screenshot on your MAC OS, then it is very simple, just press and hold command+shift+4, then selected desired area, and when you leave these buttons, the screenshot will be saved on Desktop. That's right, MAC OS saves screenshots on your desktop by default. As the number of screenshots increase, and if you don't delete or move the old ones, your desktop becomes really messy. What if we need to change the location, can we do that? Yes, of course. Here are the simple steps: Create the folder for screenshots, for example, ~/Documents/MyScreenshots. Open Terminal Execute command: defaults write com.apple.screencapture location ~/Documents/MyScreenshots Then execute command to apply the changes: killall SystemUIServer That's it. Now try taking the screenshots. You will notice that the screenshots are saved in the new folder. You need to make sure you create folder first and then execute these commands, otherwise screenshots would still appear on you

MariaDB / MySQL - Access denied for user 'root'@'localhost'

I am using MariaDB for one of the project and today I encountered some weird issue while connecting from command line. For those who are not familiar with MariaDB - it is basically open source version of MySQL . Click here to get more information about MariaDB. Also, click here to read various MariaDB articles, basic commands, etc. You can access various training tutorials here . Alright, so I was trying to login to MariaDB from my Ubuntu Command Prompt but I was constantly getting error: Access denied for user 'root'@'localhost' I was going in various directions, but the solution to this problem was very very simple. I just had to run the login command with sudo , can you believe it? If prompted, you will have to type sudo password. Just so you know, default password for MariaDB root user is <nopassword> , that's right, it does not have any password. P.S. Click here to access my other posts.

VirtualBox - Access Internet from Guest Machine

Oracle VirtualBox is a free, open source and powerful virtualization tool. Some minor configurations tweaks are required to access guest localhost from host computer. I am running VirtualBox with Ubuntu on my MAC OS. If you are attempting to access internet from your virtual machine, but if you are getting error, then here are few steps that you can try. In my scenario, I also wanted to access guest localhost from host system . I was able to access internet from the virtual machine after these steps: Shut down virtual machine In VirtualBox, right click on the virtual machine and go to " Settings " Select " Network " tab Select " Adapter1 " Select " Enable Network Adapter " checkbox Click on " Attached to " drop down box and select " NAT " Select " Adapter2 " Select " Enable Network Adapter " checkbox Click on " Attached to " drop down box and select " Host-only Adapter "

VirtualBox - Access Guest Localhost from Host Computer

Oracle VirtualBox is a free, open source and powerful virtualization tool. Some minor configurations tweaks are required to access guest localhost from host computer. I am running VirtualBox with Ubuntu on my MAC OS. One easy way to access guest localhost from host computer is to start VirtualBox with following configurations. I have Ubuntu installed on virtual machine, but steps should be similar for other OS versions as well: Shut down virtual machine In VirtualBox, right click on the virtual machine and go to " Settings " Select " Network " tab Select " Adapter1 " Select " Enable Network Adapter " checkbox Click on " Attached to " drop down box and select " Host-only Adapter " Next, go to " Advanced " section Click on " Promiscuocus Mode " drop down box and select " Allow VMs " Finally, launch virtual machine  Now, open command promt or terminal window and type " ifconfig &

Postman - Set Timeout / Think Time / Pause / Delay

Those who are involved in API or web service development should be knowing about Postman , it is one of the most popular tools to build API requests and test them. Collection Runner is one of the feature of Postman . You can create one or more requests and group them in Collection, and as name suggests, you can run the entire collection i.e. series or requests. What if you need to add "Think Time" or "Delay" or "Pause" between two requests? It is surely possible, here are some options: Using Collection Runner GUI This option will be applicable to all the requests in the collection In the Collection Runner window, enter value for Delay in milliseconds Using Command Line This option will be applicable to all the requests in the collection Newman is a comman line collection runner for Postman Command To Execute: newman run <collection-file-source> --delay-request [number] Click here to get the details about Newman Newman installation

Apache Directory Studio - An Error Has Occurred

Have you ever faced an error while launching Apache Directory Studio ? I faced this error recently on my MAC OS. Problem: I was using Apache Directory Studio for past few months without any issues, but yesterday all of a sudden I was getting below error while I was attempting to launch Apache Directory Studio application on my MAC. Note that I am using Apache Directory Studio version 2.0.0.v20130628 I open the log file to check the error message, it was so confusing. Error message was something like this: Root Cause: I recently installed latest Java version i.e. Java 9 on my MAC and I encountered this issue due to the Java version upgrade. The error message in the log file is bit misleading. Solution: To resolve this issue, you can follow below mentioned steps: Click here and refer my other post to install multiple versions of Java on your MAC OS. Make sure you install Java 7 on your MAC OS. Execute this command to get the Java 7 location: /usr/libexec/java_home

MAC OS - Install Multiple Java Versions

For those who are using MAC OS, its little tricky to install multiple Java versions. Here is the simple solution to achive this. You will need " homebrew " and some commands. To install latest Java version: Install homebrew if you do not have it already. You can find installation instructions here . Execute command: brew cask install java This will install latest Java version To install Java 7: Install homebrew if you do not have it already. You can find installation instructions here . Execute command: brew tap caskroom/versions Execute command: brew cask install java7 This will install latest Java 7 version To install Java 8: Install homebrew if you do not have it already. You can find installation instructions here . Execute command: brew tap caskroom/versions Execute command: brew cask install java8 This will install latest Java 8 version Homebrew-Cask is an extension to Homebrew. Click here to get more details. P.S. Click here to access my ot

Mule Anypoint Studio - Screen Frozen at Workspace Launcher

Recently, I thought of upgrading various softwares on my MAC OS including Java, AnypointStudio and all other softwares. So, I downloaded new version of MuleSoft Anypoint Studio on my MAC OS. After installing AnypointStudio, when I opened it for the first time, I immediately encountered an issue. Guess what, the very first screen - Workspace Launcher was frozen. I was not able to type-in workspace location, I was not able to click on browse button, I was not able to click on cancel or ok button. What a bummer!! After some trial and errors, I finally found the solution to fix the problem. I am not sure why, but looks like Anypoint Studio does not work with Java 9. As part of upgrade process, I had upgraded the Java version from 7 to 9. Either you will have to uninstall Java 9 and go back to Java 7 (I did not test this with Java 8) or you can follow below steps to make it work. Install Java 7 in addition to Java 9 on MAC OS. Get the Java 7 location, we will need this location.