Friday, May 20, 2016

Using Dlink DSL-2750U as Extending Network

Intension of this article is to use Dlink DSL-2750U as secondory router to extend network. 








  1. To Begin clean I would suggest to reset DSL-2750U router using hard reset switch on the back side of router. To do this all you need to connect your router to power supply and keep reset button pressed for few seconds. router will restart after this.
  2. Connect to "Dlink" wireless network so that you get connected to router. Access router using browser at "http://192.168.1.1". Default username and password should be "admin"
  3. In case you want to configure wireless network SSID and passkey you can do at this step. Under "SETUP" tab select "WIRELESS CONNECTION". Set SSID name at BASIC section. (You will have to reconnct to router using new ssid at this point), Next setup passkey for SSID at "ADVANCE" Section. (You will again have to reconnect to SSID using passkey).
  4. Remove Network isolation this will enable connectivity between wireless and wired devices.
  5. Remove DHCP , DNS Relay. Reboot your router. 
  6. Connect ethernet cable from primary router to first ethernet port of secondary router, and you are all set to use DSL-2750U as network extender. 

(feel free to comment as this will give scope of improving article text-- post done in hurry.)







Saturday, April 9, 2016

Using winscp for transferring files to amazon ec2 instance in windows desktop

Before we start you need to download winscp and puttygen tools

Convert you amazon pem key (ssh key) from pem to ppk file. you will get this pem key from amazon console whenever you create the new instance.
  • Start PuttyGen
  • Select "import key" under "conversations" tab from the top menu.
  • Browse and select your pem file.
  • Click on "Save Private Key" to save private key as ppk file. 

  • Install WinScp using default settings/options. 
  • Enter username and hostname (username is generally ec2-user in default OS at AWS, and hostname can be noted from aws console)
  • Click on the "advaced" button and go to "authentication" menu option.
  • Browse and select your newly created ppk file at "Private key file" box and click OK.
  • Connect/ Login to the host

Monday, January 11, 2016

Reset mysql root password | bash: mysqld_safe: command not found

Installed new mysql-server (like i did mysql  Ver 14.14 Distrib 5.7.10) and forgot the root password for mysql. here are tried steps to get your access back.

[root@buggzbox amit] systemctl stop mysqld
[root@buggzbox amit] systemctl set-environment MYSQLD_OPTS="--skip-grant-tables"
[root@buggzbox amit] systemctl start mysqld
[root@buggzbox amit] mysql -u root
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 2
Server version: 5.7.10 MySQL Community Server (GPL)

Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql>UPDATE mysql.user SET authentication_string = PASSWORD('newpassword') WHERE User = 'root' AND Host = 'localhost';
Query OK, 1 row affected, 1 warning (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 1

mysql> FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.01 sec)

mysql> quit
Bye
[root@buggzbox amit]# systemctl stop mysqld;
[root@buggzbox amit]# systemctl unset-environment MYSQLD_OPTS
[root@buggzbox amit]# systemctl start mysqld
[root@buggzbox amit]# mysql -u root -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 2
Server version: 5.7.10

Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> ^DBye
[root@buggzbox amit]#