summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCalvin <calvinm@kissingerassoc.com>2026-08-16 22:49:32 -0400
committerCalvin <calvinm@kissingerassoc.com>2026-08-16 22:49:32 -0400
commit7ba5bfafc5a8b0f09c4b88aea62e7db9206cfa38 (patch)
tree240c73b67772f8a4098e9da424a3134f2d71a273
parent1dd2bb31754781ad179d3aff7d354cc271c629b9 (diff)
svc: migrate diskparts; termrc drops the direct call
Works -- partitions are set up -- but svcinit marks it failed, because diskparts ends on a conditional that is false on a machine with no /cfg/$sysname/fsconfig, and rc returns the last command status. termrc never noticed because it ignored the status. A oneshot that does its job and exits nonzero is a shape the design has no answer for yet.
-rw-r--r--svc/lib/diskparts5
-rwxr-xr-xsvc/termrc.work3
2 files changed, 6 insertions, 2 deletions
diff --git a/svc/lib/diskparts b/svc/lib/diskparts
new file mode 100644
index 0000000..4087c03
--- /dev/null
+++ b/svc/lib/diskparts
@@ -0,0 +1,5 @@
+svc=diskparts
+ exec=/rc/bin/diskparts
+ ready=exit
+ restart=never
+ enable=yes
diff --git a/svc/termrc.work b/svc/termrc.work
index 627c8b4..9f9e005 100755
--- a/svc/termrc.work
+++ b/svc/termrc.work
@@ -56,8 +56,7 @@ if(~ $#sysname 0 || ~ $sysname ''){
echo -n $sysname >/dev/sysname
}
-# set up any partitions
-diskparts
+# diskparts is a service; see /lib/svc/diskparts
# start up local swapping
disk=`{ls /dev/sd*/swap >[2]/dev/null}