How to save password in TortoiseSVN
Follow these steps
a) Right click on local code repo
b) Go to TortoiseSVN > Settings
c) Go to “Network”
d) Browse for SSH Client and use following
“C:\Program Files\TortoiseSVN\bin\TortoisePlink.exe” – Can be found in TortoiseSVN installation folder
d) Append following replacing username and password with your user name and password
“-l username -pw password”
e) Click OK/Apply
Solr import URLs
Full-import
http://<host>:<port>/solr/dataimport?command=full-import
Delta-import
http://<host>:<port>/solr/dataimport?command=delta-import
status
http://<host>:<port>/solr/dataimport
reload-config
http://<host>:<port>/solr/dataimport?command=reload-config
abort
http://<host>:<port>/solr/dataimport?command=abort
Steps to speed up Eclipse
I found an interesting link which helped me to speed up the eclipse loading time. Let me know if that helped you.
Set autoincrement value in mysql
Sometimes it is necessary to set the starting value of MySQL auto-increment value. This can be set as
alter table table_name auto_increment=XXXX
where table_name is the name of the table and XXXX is the starting value of auto increment
Access AWS with Putty
When accessing EC2 amazon cloud, you would receive a .pem file to login to the shell. Putty does not use .pem file and you would need to convert that file to .ppk file which putty uses. In order to convert it, you would need to download puttygen.exe from the website. Run the program and follow the following steps:
- Click “Conversions” on the menu and select “Import key”
- Browse to the .pem file
- Click “Save private key” button
- You would get a warning that you are saving the key without a passphrase. Please ignore it and click “Yes”
- Save the .ppk file
On putty:
- Select the session you created and click “Load”
- Open “SSH->Auth” from the tree on the left
- Under “Private key file for authentication” browse to the recently created .ppk file
- Save the session and you are ready
MySQL export/import database
The easiest way to export is use syntax in command prompt (cmd):
mysqldump -u USER -p PASSWORD DATABASE > filename.sql
To import the same file, the syntax is:
mysql -u USER -p PASSWORD DATABASE < filename.sql
Enable XDebug on WAMP using Eclipse
For Windows machine running WAMPServer:
1) Install PDT plugin on your eclipse
2) Download XDebug to match your php
3) Install XDebug – save XDebug dll to wamp_path/bin/php/php5.3.5/ext folder
4) Enable XDebug – update php.ini file
4a) comment zend debugger information
4b) enable xdebug
[xdebug]
xdebug.remote_enable = on
xdebug.profiler_enable = off
xdebug.profiler_enable_trigger = off
; xdebug.profiler_output_name = cachegrind.out.%t.%p
xdebug.profiler_output_dir = "path to tmp folder"
xdebug.remote_handler = dbgp
xdebug.remote_host = localhost
xdebug.remote_port = 9000
5) restart apache
6) Update PHP settings on eclipse to enable XDebug
MySQL server has gone away
While importing a mysql dump file, I was receiving an error “MySQL server has gone away”. The reason is that the maximum allowed packet size was less than the dump file size.
Edit “my.ini” file and update the value for
max_allowed_packet = XXM
where XX is the maximum size.
This should fix the issue.
CSV to Excel – keep leading zeros
When opening a csv file in excel, leading zero’s are displaced as below:
if the CSV file has “010101″, when opened in excel, it becomes “10101″.
To overcome this issue, store data in CSV file as =”010101″ (add ‘equals’ sign before the first quote.). If now you would open this file in excel, the leading zeros will stay as is.
Generate SSL certificate for Tomcat
Following are the steps to create an real SSL certificate (verified by VeriSign/Thawte etc.) for Tomcat:
1. Creation of keystore
keytool -genkey -alias XXX -keyalg RSA -keystore ./XXX.keystore
2. Generation of CSR
keytool -certreq -alias XXX -file XXX.csr -keystore ./XXX.keystore
Send the generated XXX.csr to the signing authority and get the certificate from them. Save that file as “XXX.thawte”
3. Install the certificate in the keystore
keytool -import -alias XXX -trustcacerts -file XXX.thawte -keystore XXX.keystore
That’s it.
