{"id":558,"date":"2025-11-19T09:19:31","date_gmt":"2025-11-19T09:19:31","guid":{"rendered":"https:\/\/sites.wp.odu.edu\/dhill036\/?page_id=558"},"modified":"2025-11-29T10:42:51","modified_gmt":"2025-11-29T10:42:51","slug":"lab-9","status":"publish","type":"page","link":"https:\/\/sites.wp.odu.edu\/dhill036\/lab-9\/","title":{"rendered":"Lab 9 &#8211; Task Automation"},"content":{"rendered":"\n<p><strong>My Experience<\/strong> <strong>on This Lab <\/strong><br>In this assignment, I automated system backups using Bash scripts and <code><strong>crontab<\/strong><\/code>. I created a user (Alice), wrote a script to archive and compress her home directory with a timestamped filename, and moved the backup to <code><strong>\/var\/backups<\/strong><\/code>. I then scheduled the script to run every 3 minutes and later removed the cron job. For extra credit, I added a cleanup script that deletes older backups when the count exceeds a set limit.<\/p>\n\n\n\n<p><strong>Key Concepts:<\/strong><br>I practiced using variables, timestamps, compression, cron scheduling, and permissions. The lab showed how automation helps maintain regular backups and manage system storage.<\/p>\n\n\n\n<p><strong>Challenges:<\/strong><br>The main challenges were formatting the date correctly and handling write permissions for <code><strong>\/var\/backups<\/strong><\/code>.<\/p>\n\n\n<b>PDF Embedder requires a url attribute<\/b>\n\n\n<div data-wp-interactive=\"\" class=\"wp-block-file\"><object data-wp-bind--hidden=\"!selectors.core.file.hasPdfPreview\" hidden class=\"wp-block-file__embed\" data=\"https:\/\/sites.wp.odu.edu\/dhill036\/wp-content\/uploads\/sites\/38343\/2025\/11\/annotated-Lab209.pdf\" type=\"application\/pdf\" style=\"width:100%;height:600px\" aria-label=\"Embed of Lab 9.\"><\/object><a id=\"wp-block-file--media-a2fcd03b-14c7-46e7-b248-f9e20503172f\" href=\"https:\/\/sites.wp.odu.edu\/dhill036\/wp-content\/uploads\/sites\/38343\/2025\/11\/annotated-Lab209.pdf\">Lab 9<\/a><a href=\"https:\/\/sites.wp.odu.edu\/dhill036\/wp-content\/uploads\/sites\/38343\/2025\/11\/annotated-Lab209.pdf\" class=\"wp-block-file__button wp-element-button\" download aria-describedby=\"wp-block-file--media-a2fcd03b-14c7-46e7-b248-f9e20503172f\">Download<\/a><\/div>\n","protected":false},"excerpt":{"rendered":"<p>My Experience on This Lab In this assignment, I automated system backups using Bash scripts and crontab. I created a user (Alice), wrote a script to archive and compress her home directory with a timestamped filename, and moved the backup to \/var\/backups. I then scheduled the script to run every 3 minutes and later removed&#8230; <\/p>\n<div class=\"link-more\"><a href=\"https:\/\/sites.wp.odu.edu\/dhill036\/lab-9\/\">Read More<\/a><\/div>\n","protected":false},"author":30353,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"_links":{"self":[{"href":"https:\/\/sites.wp.odu.edu\/dhill036\/wp-json\/wp\/v2\/pages\/558"}],"collection":[{"href":"https:\/\/sites.wp.odu.edu\/dhill036\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/sites.wp.odu.edu\/dhill036\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/sites.wp.odu.edu\/dhill036\/wp-json\/wp\/v2\/users\/30353"}],"replies":[{"embeddable":true,"href":"https:\/\/sites.wp.odu.edu\/dhill036\/wp-json\/wp\/v2\/comments?post=558"}],"version-history":[{"count":4,"href":"https:\/\/sites.wp.odu.edu\/dhill036\/wp-json\/wp\/v2\/pages\/558\/revisions"}],"predecessor-version":[{"id":581,"href":"https:\/\/sites.wp.odu.edu\/dhill036\/wp-json\/wp\/v2\/pages\/558\/revisions\/581"}],"wp:attachment":[{"href":"https:\/\/sites.wp.odu.edu\/dhill036\/wp-json\/wp\/v2\/media?parent=558"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}