{"id":11,"date":"2012-05-24T16:58:06","date_gmt":"2012-05-24T16:58:06","guid":{"rendered":"http:\/\/blog.law.gmu.edu\/webservices\/?p=11"},"modified":"2012-05-24T16:58:06","modified_gmt":"2012-05-24T16:58:06","slug":"frequently-used-linux-command-lines","status":"publish","type":"post","link":"https:\/\/sls.gmu.edu\/web\/2012\/05\/24\/frequently-used-linux-command-lines\/","title":{"rendered":"Frequently Used Linux Command Lines"},"content":{"rendered":"<p><strong>Install WordPress<\/strong><br \/>\nwget https:\/\/wordpress.org\/latest.tar.gz<br \/>\ntar xfz latest.tar.gz<br \/>\ncp -r * ~\/public_html\/your\/website\/folder\/<\/p>\n<p><strong>Change Permissions (rwx =&gt; 4 + 2 + 1 = 7)<\/strong><br \/>\nFor Directories: find \/path\/to\/your\/directory\/ -type d -exec chmod 755 {} \\;<br \/>\nFor Files:  find \/path\/to\/your\/file\/ -type f -exec chmod 644 {} \\;<\/p>\n<p><strong>Permissions<\/strong><br \/>\nchmod -R 755 directory<br \/>\nchmod -R 644 files<\/p>\n<p><strong>Remove files and directory<\/strong> (use carefully)<br \/>\nrm -rf YourDirectory<\/p>\n<p><strong>Change Owner<\/strong><br \/>\nchown -R apache new_name (change entire directory)<\/p>\n<p>Remane Directory<br \/>\nmv {old} {new}<\/p>\n<p><strong>Database<\/strong><br \/>\nTo access database: mysql -u root -p<br \/>\nmysql&gt; create database [database name];<br \/>\nmysql&gt; show databases;<br \/>\nmysql&gt; drop database [database name];<br \/>\n<a href=\"http:\/\/www.pantz.org\/software\/mysql\/mysqlcommands.html\">More<\/a><\/p>\n<p><strong>VI editor<\/strong><br \/>\nReference: <a href=\"http:\/\/amath.colorado.edu\/computing\/unix\/vi\/\">Using the VI editor<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Install WordPress wget https:\/\/wordpress.org\/latest.tar.gz tar xfz latest.tar.gz cp -r * ~\/public_html\/your\/website\/folder\/ Change Permissions (rwx =&gt; 4 + 2 + 1 = 7) For Directories: find \/path\/to\/your\/directory\/ -type d -exec chmod 755 {} \\; For Files: find \/path\/to\/your\/file\/ -type f -exec chmod 644 {} \\; Permissions chmod -R 755 directory chmod -R 644 files Remove files &hellip; <a href=\"https:\/\/sls.gmu.edu\/web\/2012\/05\/24\/frequently-used-linux-command-lines\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Frequently Used Linux Command Lines&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"inline_featured_image":false,"footnotes":""},"categories":[5],"tags":[20],"class_list":["post-11","post","type-post","status-publish","format-standard","hentry","category-command-lines","tag-linux"],"_links":{"self":[{"href":"https:\/\/sls.gmu.edu\/web\/wp-json\/wp\/v2\/posts\/11","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sls.gmu.edu\/web\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sls.gmu.edu\/web\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sls.gmu.edu\/web\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/sls.gmu.edu\/web\/wp-json\/wp\/v2\/comments?post=11"}],"version-history":[{"count":0,"href":"https:\/\/sls.gmu.edu\/web\/wp-json\/wp\/v2\/posts\/11\/revisions"}],"wp:attachment":[{"href":"https:\/\/sls.gmu.edu\/web\/wp-json\/wp\/v2\/media?parent=11"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sls.gmu.edu\/web\/wp-json\/wp\/v2\/categories?post=11"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sls.gmu.edu\/web\/wp-json\/wp\/v2\/tags?post=11"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}