Tuesday, September 16, 2014

Ubuntu password reset

Power on the PC
On GRUB Menu display----------------------
First, you have to reboot into recovery mode.
If you have a single-boot (Ubuntu is the only operating system on your computer), to get the boot menu to show, you have to hold down the Shift key during bootup.
If you have a dual-boot (Ubuntu is installed next to Windows, another Linux operating system, or Mac OS X; and you choose at boot time which operating system to boot into), the boot menu should appear without the need to hold down the Shift key.


From the boot menu, select recovery mode, which is usually the second boot option.




After you select recovery mode and wait for all the boot-up processes to finish, you'll be presented with a few options. In this case, you want the Drop to root shell prompt option so press the Down arrow to get to that option, and then press Enter to select it.
The root account is the ultimate administrator and can do anything to the Ubuntu installation (including erase it), so please be careful with what commands you enter in the root terminal.
In recent versions of Ubuntu, the filesystem is mounted as read-only, so you need to enter the follow command to get it to remount as read-write, which will allow you to make changes:



mount -o rw,remount /


If you have forgotten your username as well, type
ls /home
That's a lowercase L, by the way, not a capital i, in ls. You should then see a list of the users on your Ubuntu installation. In this case, I'm going to reset Susan Brownmiller's password. To reset the password, type
passwd username
where username is the username you want to reset. In this case, I want to reset Susan's password, so I type
passwd susan
You'll then be prompted for a new password. When you type the password you will get no visual response acknowledging your typing. Your password is still being accepted. Just type the password and hit Enter when you're done. You'll be prompted to retype the password. Do so and hit Enter again.
Now the password should be reset. Type
exit
to return to the recovery menu.

 
After you get back to the recovery menu, select resume normal boot, and use Ubuntu as you normally would—only this time, you actually know the password!


Another alternative approach if the above approach is not working....................
http://www.faqforge.com/linux/reset-root-password-ubuntu-linux-without-cd/

Sunday, July 20, 2014

Ubuntu 14.04 Flicker problems............

Ubuntu 14.04 Problems

Screen Flicker----------------

Working! Just installing latest 3.15 kernel (I tried 3.15 RC8 and 3.15.3 fromhttp://kernel.ubuntu.com/~kernel-ppa/mainline/v3.15.3-utopic/.
It works like a charm!
files to download 3.15.3 for 64-bit system:
  • linux-headers-3.15.3-031503-generic_3.15.3-031503.201407010040_amd64.deb
  • linux-headers-3.15.3-031503_3.15.3-031503.201407010040_all.deb
  • linux-image-3.15.3-031503-generic_3.15.3-031503.201407010040_amd64.deb
files to download 3.15.3 for 32-bit system:
  • linux-headers-3.15.3-031503-generic_3.15.3-031503.201407010040_i386.deb
  • linux-headers-3.15.3-031503_3.15.3-031503.201407010040_i386.deb
  • linux-image-3.15.3-031503-generic_3.15.3-031503.201407010040_i386.deb
Type in terminal:
sudo dpkg -i *.deb

Thursday, April 17, 2014

Rack awareness and java in ubuntu

best :---
https://developer.yahoo.com/hadoop/tutorial/module2.html

http://ofirm.wordpress.com/2014/01/09/exploring-the-hadoop-network-topology/

 http://fendertech.blogspot.in/2013/07/hadoop-rack-awareness-104.html
------------------------------------------------------------------------------------------------------------
http://www.michael-noll.com/blog/2011/03/28/hadoop-space-quotas-hdfs-block-size-replication-and-small-files/

http://stackoverflow.com/questions/17799535/hdfs-reduced-replication-factor

http://stackoverflow.com/questions/20119320/when-i-store-files-in-hdfs-will-they-be-replicated

http://architects.dzone.com/articles/how-hdfs-does-replication

http://coenraets.org/blog/2012/10/real-time-web-analytics-with-node-js-and-socket-io/

http://bradhedlund.com/2011/09/10/understanding-hadoop-clusters-and-the-network

https://issues.apache.org/jira/browse/HADOOP-692

------------------------------------------------------------------------------------------------------------
autoreconf error in hadoop build--------------
apt-get -y install maven build-essential autoconf automake libtool cmake zlib1g-dev pkg-config libssl-dev
------------------------------------------------------------------------------------------------------------

    Download Java SE 7 JDK for Linux x86 archive. At the time of writing, the file I'm using is jdk-7u21-linux-i586.tar.gz, but the filename will change as updates are released.
    Apparently there is no longer a jvm folder, so create one.

    sudo mkdir /usr/lib/jvm

    Move the archive to the jvm folder

    sudo mv jdk-7u21-linux-i586.tar.gz /usr/lib/jvm/

    Change to the jvm folder and extract the JDK from the archive

    cd /usr/lib/jvm

    sudo tar zxvf jdk-7u21-linux-i586.tar.gz

    Everything will be extracted to a new jdk1.7.0_21 folder and you can delete
the archive file now.
 
sudo update-alternatives --install "/usr/bin/javac" "javac" "/usr/lib/jvm/java-6.31-oracle/bin/javac" 1
sudo update-alternatives --config javac
 
similarly for java use java

sudo update-alternatives --install "/usr/bin/java" "java" "/usr/lib/jvm/java-6.31-oracle/jre/bin/java" 1
sudo update-alternatives --config java

Double-check the version
    java -version

from----------- http://www.printandweb.ca/2013/04/manually-install-oracle-jdk-7-for.html


http://www.linuxquestions.org/questions/linux-newbie-8/lost-ubuntu-after-installing-opensuse-932336/

Sunday, April 6, 2014

ssh settings in hadoop...........(passwordless login)

on the host you will connect FROM:
generate the public private keys
> ssh-keygen -t dsa -P '' -f ~/.ssh/id_dsa
copy the public key to every host you will connect TO:
> scp ~/.ssh/id_dsa.pub my_user_id@1.2.3.4:~/.ssh/id_dsa.pub
* this should prompt you for a password
shell into the remote machine
> ssh my_user_id@1.2.3.4
authorize the key by adding it to the list of authorized keys
> cat ~/.ssh/id_dsa.pub >> ~/.ssh/authorized_keys
log out of the current shell
> exit
test that you can log in with no password

if problems persist plz refer:-
http://allthingshadoop.com/?s=Hadoop+Cluster+Setup%2C+SSH+Key+Authentication

http://ambari.apache.org/1.2.0/installing-hadoop-using-ambari/content/ambari-chap1-5-2.html

 

Wednesday, March 26, 2014

proxy settings in oracle solaris 11


  for gateway settings : 
   route add default 10.1.0.1
  for proxy settings :
  1 export http_proxy=http://nihita-me-cs-2010:abc123@10.25.0.4:3128
  2 export https_proxy=http://nihita-me-cs-2010:abc123@10.25.0.4:3128
  3 svccfg -s system-repository:default setprop config/http_proxy = http://nihita-me-cs-2010:abc123@10.25.0.4:3128
  4 svccfg -s system-repository:default setprop config/https_proxy = http://nihita-me-cs-2010:abc123@10.25.0.4:3128
 5 svcadm refresh system-repository
 6 svcprop -p config/http_proxy system-repository
 7 svcprop -p config/https_proxy system-repository

http://www.thewireframecommunity.com/node/29

http://www.cyberciti.biz/faq/linux-unix-set-proxy-environment-variable/

http://gurkulindia.com/main/manpages/solaris-11-image-packaging-systems-quick-reference/#

http://docs.oracle.com/cd/E23824_01/html/821-1460/glqjr.html



  

Tuesday, March 25, 2014

MySQL Utilities

mysqldump is an effective tool to backup MySQL database. It creates a *.sql file with DROP table, CREATE table and INSERT into sql-statements of the source database. To restore the database,  execute the *.sql file on destination database.  For MyISAM, use mysqlhotcopy method that we explained earlier, as it is faster for MyISAM tables.

backup: # mysqldump -u root -p[root_password] [database_name] > dumpfilename.sql

restore:# mysql -u root -p[root_password] [database_name] < dumpfilename.sql
 
 
Random Data 

http://stackoverflow.com/questions/10788285/how-to-update-insert-random-dates-in-sql-within-a-specified-date-range