{"id":142,"date":"2010-03-14T12:02:56","date_gmt":"2010-03-14T19:02:56","guid":{"rendered":"http:\/\/www.dreness.com\/blog\/?p=142"},"modified":"2010-03-14T12:03:23","modified_gmt":"2010-03-14T19:03:23","slug":"of-logs-and-non-boot-volumes","status":"publish","type":"post","link":"https:\/\/dreness.com\/blog\/archives\/142","title":{"rendered":"Of logs and non-boot volumes"},"content":{"rendered":"<p>It&#8217;s a beautiful Sunday morning, and as you wait for the coffee to start working, you figure it&#8217;s probably about time that you started on those benchmark results that have to be done by Monday. You&#8217;re sitting there thinking &#8220;MAN I wish I&#8217;d provisioned a larger boot volume for these Mac Minis, I keep filling it up with logs! Oh wait, I have a smart idea that I acquired from thinking! Maybe I can use the non-boot volume to hold the computer software logs, since it has SO much more space! Ok then, all I need to do is find the buttons for making a symbolic link from \/var\/log to \/Volumes\/foo\/log, and then&#8230; it&#8217;ll work! Yeah!&#8221;<\/p>\n<p>And lo, it did work, for a time. Imagine my surprise when 2 out of 20 of my mac mini-ons became unusable for my nefarious purposes of generating ical server load because the data volume used by the load simulator was somehow mounted read-only! The two failing minions also happened to be the two that were recently rebooted, after moving their power cables to different power circuits (to prevent blowing breakers, but that&#8217;s a whole other story). I didn&#8217;t ask for this crazy read-only nonsense!<\/p>\n<p>Volumes get mounted read-only early at boot time, every time you boot, and that is normal. Usually, they are very quickly re-mounted in read-write mode, which is&#8230; ya know, more useful and stuff. My best guess at the fail here is that some part of the logging subsystem tried to open \/Volumes\/foo while it was still read-only, and SUCCEEDED when it probably should have failed. After all, what is the point of a logging system that mounts its log targets read-only, other than to prevent re-mounting of that filesystem read-write!<\/p>\n<p>It appears that this happens. So, don&#8217;t do it, unless you wanted both no logging and a read-only data volume.<\/p>\n<p>Recovering from this was not as easy as it should have been. On the first minion, I actually got beyond nuking \/Volumes\/foo until I remembered the \/var\/log symlink, so then I removed the symlink, re-created \/var\/log, and rebooted &#8211; this fixed minion number one. The SECOND minion was weirder. I removed the \/var\/log symlink, made a local \/var\/log, then rebooted &#8211; but \/Volumes\/foo still came back read-only! What?! Well I&#8217;m on a schedule so I just blew that one away too (diskutil eraseVolume), and then it came back ok &#8211; *after another reboot*. Funky.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>It&#8217;s a beautiful Sunday morning, and as you wait for the coffee to start working, you figure it&#8217;s probably about time that you started on those benchmark results that have to be done by Monday. You&#8217;re sitting there thinking &#8220;MAN &hellip; <a href=\"https:\/\/dreness.com\/blog\/archives\/142\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,3,14,13],"tags":[],"class_list":["post-142","post","type-post","status-publish","format-standard","hentry","category-os-x","category-os-x-server","category-pro-tip","category-the-more-you-know"],"_links":{"self":[{"href":"https:\/\/dreness.com\/blog\/wp-json\/wp\/v2\/posts\/142","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dreness.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dreness.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dreness.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dreness.com\/blog\/wp-json\/wp\/v2\/comments?post=142"}],"version-history":[{"count":2,"href":"https:\/\/dreness.com\/blog\/wp-json\/wp\/v2\/posts\/142\/revisions"}],"predecessor-version":[{"id":144,"href":"https:\/\/dreness.com\/blog\/wp-json\/wp\/v2\/posts\/142\/revisions\/144"}],"wp:attachment":[{"href":"https:\/\/dreness.com\/blog\/wp-json\/wp\/v2\/media?parent=142"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dreness.com\/blog\/wp-json\/wp\/v2\/categories?post=142"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dreness.com\/blog\/wp-json\/wp\/v2\/tags?post=142"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}