Tips &Tricks

0

Print a line of a local file in using command line

Print 15th line using sed sed –n “15p” hello-world.js Print 15–25 line using sed sed –n “15,25p” hello-world.js Print 15–25 line with line num­bers using sed sed –n “10,20p” hello-world.js | less –N

0

A telnet to a server

tel­net <ip-address> <port-number> tel­net <name-of-the-server> <port-number> Most of the time peo­ple check con­nec­tiv­ity via ping <ip-address> But ping com­mand lis­tens on other ports than you expect. Hence, you might get response back from server but…

0

Find hostname in mac

Run the fol­low­ing com­mand in your ter­mi­nal. echo $HOSTNAME It is the sim­plest way to find the host­name in MAC from your terminal.

0

Error: listen eacces

Did you try run­ning your appli­ca­tion on port# < 1024 and faced the fol­low­ing error? Error: lis­ten EACCES It means you do not have enough per­mis­sion to lis­ten on port# < 1024. If you run…

0

Update firefox on Ubuntu

Do you want to get the lat­est ver­sion of the fire­fox on Ubuntu? Here is the solu­tion: sudo apt-get update sudo apt-get install fire­fox sudo apt-get upgrade Fur­ther Reading

Dropwizard 0.8 and Jetty fail return 404 on resources 0

Dropwizard 0.8 and Jetty fail return 404 on resources

Sim­ple hello world drop­wiz­ard appli­ca­tion throws the error below– HTTP ERROR 404 Prob­lem access­ing /hello-world. Rea­son: Not Found While app logs says — return 200 for that request. Rea­son: If you look closely in terminal,…