WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: copy2fs boot code  (Read 3241 times)

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
copy2fs boot code
« on: October 18, 2016, 08:16:26 AM »
Is there a reason for no  copy2fs  boot code?

If I get it right, when booting off of CD, there is no way to eject the CD after boot, unless it was remastered with added  /etc/sysconfig/tcedir/copy2fs.flg .

I'm currently thinking about how to add the  copy2fs  boot code to  tc-config  and   tce-setup  but please stop me if you know this would break things, as I'm not familiar with every method Core offers for loading extension (builtin/*.gz, *.tcz, PXE, etc.).
Download a copy and keep it handy: Core book ;)

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: copy2fs boot code
« Reply #1 on: October 18, 2016, 08:39:12 AM »
Hmm, am I going too easy?
This works on my installation:
Code: [Select]
--- tce-setup.old
+++ tce-setup.new
@@ -35,6 +35,7 @@
  mkdir "$TCEDIR"/optional
  chown -R "$USER".staff "$TCEDIR"
  fi
+ [ -n "$COPY2FS" ] && touch "$TCEDIR"/copy2fs.flg
  [ -L /etc/sysconfig/tcedir ] && rm -f /etc/sysconfig/tcedir
  ln -sf "$TCEDIR" /etc/sysconfig/tcedir
  chown -R "$USER".staff "$TCEINSTALLED"
@@ -112,6 +113,7 @@
  case $i in
  cde) CDE=1 ;;
  base) ONLYBASE=1 ;;
+ copy2fs) COPY2FS=1 ;;
  esac
 done
 

Download a copy and keep it handy: Core book ;)

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: copy2fs boot code
« Reply #2 on: October 18, 2016, 08:49:52 AM »
Yeah, too easy. Doesn't work for  base .
I might wait for comments before I dig further.
Download a copy and keep it handy: Core book ;)

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14819
Re: copy2fs boot code
« Reply #3 on: October 18, 2016, 08:56:45 AM »
If I get it right, when booting off of CD, there is no way to eject the CD after boot, unless it was remastered with added  /etc/sysconfig/tcedir/copy2fs.flg .

This works for me:
Code: [Select]
$ sudo umount /mnt/sr0
$ eject

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: copy2fs boot code
« Reply #4 on: October 18, 2016, 09:03:32 AM »
Really? Shouldn't it refuse to un-mount while there are extensions mounted from sr0 (resource or device busy) ?
Download a copy and keep it handy: Core book ;)

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14819
Re: copy2fs boot code
« Reply #5 on: October 18, 2016, 09:39:11 AM »
the extensions are loaded to ram, no?

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: copy2fs boot code
« Reply #6 on: October 18, 2016, 10:06:09 AM »
Oh, yes!
There is  /cde/copy2fs.lst , containing every extension stored in  /cde/optional . Big oversight. :p
This probably reduces my efforts by some degree as CDs are not affected.
I'd still find a  copy2fs  boot code useful but I'm realizing now that it's not really required. Maybe I'll come back to this if I can get it done without complicating things.
Download a copy and keep it handy: Core book ;)