{"id":690,"date":"2024-07-23T21:29:10","date_gmt":"2024-07-23T18:29:10","guid":{"rendered":"https:\/\/harrykuch.ru\/wordpress\/?p=690"},"modified":"2025-05-15T15:37:57","modified_gmt":"2025-05-15T12:37:57","slug":"%d0%bd%d0%b0%d1%81%d1%82%d1%80%d0%be%d0%b9%d0%ba%d0%b0-%d1%80%d0%b5%d0%b7%d0%b5%d1%80%d0%b2%d0%bd%d0%be%d0%b3%d0%be-%d0%ba%d0%be%d0%bf%d0%b8%d1%80%d0%be%d0%b2%d0%b0%d0%bd%d0%b8%d1%8f-%d0%b4%d0%b8","status":"publish","type":"post","link":"https:\/\/harrykuch.ru\/wordpress\/?p=690","title":{"rendered":"\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0440\u0435\u0437\u0435\u0440\u0432\u043d\u043e\u0433\u043e \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u0438\u0441\u043a\u0430 \u0441 \u0434\u0430\u043d\u043d\u044b\u043c\u0438 Nextcloud \u0438 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 Raspberry \u0447\u0435\u0440\u0435\u0437 cron"},"content":{"rendered":"<p>\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u043c \u0432\u0442\u043e\u0440\u043e\u0439 \u0436\u0435\u0441\u0442\u043a\u0438\u0439 \u0434\u0438\u0441\u043a \u043a \u043c\u0430\u043b\u0438\u043d\u0435 \u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u043c \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043d\u0430 \u043d\u0435\u0433\u043e \u0444\u0430\u0439\u043b\u043e\u0432 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \u043e\u0431\u043b\u0430\u043a\u0430.<\/p>\n<p>\u041d\u0430\u0431\u0438\u0440\u0430\u0435\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443:<\/p>\n<pre>ls -l \/dev\/disk\/by-uuid<\/pre>\n<p>\u043d\u0430\u0445\u043e\u0434\u0438\u043c UUID<\/p>\n<p><a href=\"https:\/\/harrykuch.ru\/wordpress\/wp-content\/uploads\/2024\/07\/2024-07-23_20-47-53.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignleft wp-image-691\" src=\"https:\/\/harrykuch.ru\/wordpress\/wp-content\/uploads\/2024\/07\/2024-07-23_20-47-53.png\" alt=\"\" width=\"460\" height=\"168\" srcset=\"https:\/\/harrykuch.ru\/wordpress\/wp-content\/uploads\/2024\/07\/2024-07-23_20-47-53.png 676w, https:\/\/harrykuch.ru\/wordpress\/wp-content\/uploads\/2024\/07\/2024-07-23_20-47-53-300x110.png 300w\" sizes=\"auto, (max-width: 460px) 100vw, 460px\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p><!--more-->\u0421\u043e\u0437\u0434\u0430\u0435\u043c \u0442\u043e\u0447\u043a\u0443 \u043c\u043e\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f. \u0412 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u044d\u0442\u043e hdd2:<\/p>\n<pre>sudo mkdir \/mnt\/hdd2<\/pre>\n<p>\u041e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c fstab:<\/p>\n<pre>sudo nano \/etc\/fstab<\/pre>\n<p>\u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0441\u0442\u0440\u043e\u043a\u0443:<\/p>\n<pre>UUID=A69E29769E294063 \/mnt\/hdd2 ntfs nofail,uid=user,gid=group,dmask=0007 0 0<\/pre>\n<p>\u0412 \u044d\u0442\u043e \u0441\u0442\u0440\u043e\u043a\u0435 \u0435\u0441\u0442\u044c UUID \u0434\u0438\u0441\u043a\u0430 A69E29769E294063, \u0442\u043e\u0447\u043a\u0430 \u043c\u043e\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \/mnt\/hdd2, \u0444\u043e\u0440\u043c\u0430\u0442 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0434\u0438\u0441\u043a\u0430 &#8212; ntfs (\u0432\u044b \u0432\u0435\u0434\u044c \u0444\u043e\u0440\u043c\u0430\u0442\u0438\u0440\u043e\u0432\u0430\u043b\u0438 \u0434\u0438\u0441\u043a \u0432 \u043d\u0442\u0444\u0441\u0435, \u0434\u0430?), \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0438 \u0433\u0440\u0443\u043f\u043f\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f &#8212; \u0432\u043c\u0435\u0441\u0442\u043e <em>user<\/em> \u0438 <em>group<\/em> \u043f\u043e\u0441\u0442\u0430\u0432\u044c\u0442\u0435 \u0441\u0432\u043e\u0435\u0433\u043e \u044e\u0437\u0435\u0440\u0430 \u0438 \u0433\u0440\u0443\u043f\u043f\u0443. dmask=0007 0 0 &#8212; \u043e\u0441\u0442\u0430\u0432\u044c\u0442\u0435 \u043a\u0430\u043a \u0435\u0441\u0442\u044c. \u0422.\u0435. \u0434\u0438\u0441\u043a\u043e\u043c \u0441 \u0434\u0430\u043d\u043d\u044b\u043c\u0438 Nextcloud \u0443 \u043d\u0430\u0441 \u0432\u043b\u0430\u0434\u0435\u0435\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c www-data, \u0430 \u0434\u0438\u0441\u043a\u043e\u043c \u0434\u043b\u044f \u0431\u044d\u043a\u0430\u043f\u0430 &#8212; \u0412\u0430\u0448 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c.<\/p>\n<p>\u041f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u043c\u0441\u044f<\/p>\n<pre>sudo reboot<\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0412\u044b \u0432\u0441\u0435 \u0441\u0434\u0435\u043b\u0430\u043b\u0438 \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e, \u0442\u043e \u0441\u0438\u0441\u0442\u0435\u043c\u0430 \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u0441\u044f. \u041e\u0448\u0438\u0431\u043a\u0438 \u0432 \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0438 \u0444\u0430\u0439\u043b\u0430 ftab \u043c\u043e\u0433\u0443\u0442 \u043f\u0440\u0438\u0432\u0435\u0441\u0442\u0438 \u043a \u0442\u043e\u043c\u0443, \u0447\u0442\u043e Raspbian \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u043d\u0435\u0442 \u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0442\u044c\u0441\u044f \u0434\u043e \u043a\u043e\u043d\u0446\u0430, \u0432\u044b\u0434\u0430\u0432\u0430\u044f \u0432 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 \u043e\u0431 \u043e\u0448\u0438\u0431\u043a\u0435 \u2014 \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f \u043f\u0435\u0440\u0435\u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0441\u0438\u0441\u0442\u0435\u043c\u0443.<\/p>\n<h3 style=\"text-align: center;\">\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0440\u0435\u0437\u0435\u0440\u0432\u043d\u043e\u0433\u043e \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u0438\u0441\u043a\u0430 \u0441 \u0434\u0430\u043d\u043d\u044b\u043c\u0438, \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 Raspberry \u0447\u0435\u0440\u0435\u0437 cron.<\/h3>\n<p><strong>1. \u0421\u043e\u0437\u0434\u0430\u0435\u043c \u0444\u0430\u0439\u043b Service.sh \u043d\u0430 \u0440\u0430\u0431\u043e\u0447\u0435\u043c \u0441\u0442\u043e\u043b\u0435<\/strong><\/p>\n<pre>touch \/home\/harrykuch\/Desktop\/Service.sh<\/pre>\n<p>\u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c \u0435\u0433\u043e \u0434\u043b\u044f \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439:<\/p>\n<pre>nano \/home\/harrykuch\/Desktop\/Service.sh<\/pre>\n<p>\u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0441\u0442\u0440\u043e\u043a\u0438:<\/p>\n<pre>#\u044d\u0442\u043e \u0444\u0430\u0439\u043b \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0432\u0432\u043e\u0434\u0430 \u043e\u0431\u043b\u0430\u043a\u0430 \u0432 \u0440\u0435\u0436\u0438\u043c \u043e\u0431\u0441\u043b\u0443\u0436\u0438\u0432\u0430\u043d\u0438\u044f, \u0437\u0430\u0442\u0435\u043c \u0440\u0435\u0437\u0435\u0440\u0432\u043d\u043e\u0433\u043e \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \r\n#\u0431\u0430\u0437\u044b \u0444\u0430\u0439\u043b\u043e\u0432 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \u043d\u0430 \u0440\u0435\u0437\u0435\u0440\u0432\u043d\u044b\u0439 \u0434\u0438\u0441\u043a \r\n#\u0438 \u043f\u043e\u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435 \u0432\u044b\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u0440\u0435\u0436\u0438\u043c\u0430 \u043e\u0431\u0441\u043b\u0443\u0436\u0438\u0432\u0430\u043d\u0438\u044f \u0438 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 raspberry.\u2029\r\n#!\/bin\/bash\u2029\r\nsudo -u www-data php \/var\/www\/html\/nextcloud\/occ maintenance:mode --on\u2029\r\nrsync -azrv --delete \/mnt\/data2\/data \/mnt\/hdd2\/\u2029\r\nsudo -u www-data php \/var\/www\/html\/nextcloud\/occ maintenance:mode --off\u2029\r\nsudo reboot<\/pre>\n<p>\u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c: CTRL + X, Y, Enter.<\/p>\n<p>\u0414\u0435\u043b\u0430\u0435\u043c \u0444\u0430\u0439\u043b \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u044b\u043c:<\/p>\n<pre>chmod +x \/home\/harrykuch\/Desktop\/Service.sh<\/pre>\n<p><strong>2. \u0421\u043e\u0437\u0434\u0430\u0435\u043c \u0444\u0430\u0439\u043b Reboot.sh \u043d\u0430 \u0440\u0430\u0431\u043e\u0447\u0435\u043c \u0441\u0442\u043e\u043b\u0435:<\/strong><\/p>\n<pre>touch \/home\/harrykuch\/Desktop\/Reboot.sh<\/pre>\n<p>\u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c \u0435\u0433\u043e \u0434\u043b\u044f \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439:<\/p>\n<pre>nano \/home\/harrykuch\/Desktop\/Reboot.sh<\/pre>\n<p>\u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0441\u0442\u0440\u043e\u043a\u0438:<\/p>\n<pre>#\u044d\u0442\u043e \u0444\u0430\u0439\u043b \u0434\u043b\u044f \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 raspberry.\u2029\r\n#!\/bin\/bash\u2029\r\nsudo reboot<\/pre>\n<p>\u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c: CTRL + X, Y, Enter.<\/p>\n<p>\u0414\u0435\u043b\u0430\u0435\u043c \u0444\u0430\u0439\u043b \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u044b\u043c:<\/p>\n<pre>chmod +x \/home\/harrykuch\/Desktop\/Reboot.sh<\/pre>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0443 \u043d\u0430\u0441 \u043d\u0430 \u0440\u0430\u0431\u043e\u0447\u0435\u043c \u0441\u0442\u043e\u043b\u0435 \u0435\u0441\u0442\u044c \u0444\u0430\u0439\u043b\u044b Reboot.sh \u0438 Service.sh<\/p>\n<p><strong>3. \u0412\u0445\u043e\u0434\u0438\u043c \u0432 \u0445\u0440\u043e\u043d\u0442\u0430\u0431:<\/strong><\/p>\n<pre>crontab -e<\/pre>\n<p>\u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0432\u043d\u0438\u0437\u0443 \u0441\u0442\u0440\u043e\u043a\u0438:<\/p>\n<pre>#\u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430 Service.sh - \u0440\u0435\u0437\u0435\u0440\u0432\u043d\u043e\u0435 \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0434\u0430\u043d\u043d\u044b\u0445 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \r\n#\u0441 \u043f\u043e\u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u043e\u0439 \u043a\u0430\u0436\u0434\u043e\u0435 \u0432\u043e\u0441\u043a\u0440\u0435\u0441\u0435\u043d\u044c\u0435 \u0432 1-00.\u2029\r\n0 1 * * 1 \/home\/harrykuch\/Desktop\/Service.sh\r\n#\u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430 Reboot.sh - \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0430 \u043a\u0430\u0436\u0434\u0443\u044e \u0441\u0440\u0435\u0434\u0443 \u0432 3-00\u2029\r\n0 3 * * 4 \/home\/harrykuch\/Desktop\/Reboot.sh<\/pre>\n<p>\u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c: CTRL + X, Y, Enter.<\/p>\n<p>\u0412\u0441\u0451.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u043c \u0432\u0442\u043e\u0440\u043e\u0439 \u0436\u0435\u0441\u0442\u043a\u0438\u0439 \u0434\u0438\u0441\u043a \u043a \u043c\u0430\u043b\u0438\u043d\u0435 \u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u043c \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043d\u0430 \u043d\u0435\u0433\u043e \u0444\u0430\u0439\u043b\u043e\u0432 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \u043e\u0431\u043b\u0430\u043a\u0430. \u041d\u0430\u0431\u0438\u0440\u0430\u0435\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443: ls -l \/dev\/disk\/by-uuid \u043d\u0430\u0445\u043e\u0434\u0438\u043c UUID &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[],"class_list":["post-690","post","type-post","status-publish","format-standard","hentry","category-raspberry_pi"],"_links":{"self":[{"href":"https:\/\/harrykuch.ru\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/690","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/harrykuch.ru\/wordpress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/harrykuch.ru\/wordpress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/harrykuch.ru\/wordpress\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/harrykuch.ru\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=690"}],"version-history":[{"count":14,"href":"https:\/\/harrykuch.ru\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/690\/revisions"}],"predecessor-version":[{"id":1182,"href":"https:\/\/harrykuch.ru\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/690\/revisions\/1182"}],"wp:attachment":[{"href":"https:\/\/harrykuch.ru\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=690"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/harrykuch.ru\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=690"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/harrykuch.ru\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=690"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}