Jump to content

How do you guys review your kexts on your EFI partition?


iCF-74 ToughMac
 Share

26 posts in this topic

Recommended Posts

I've gotten lazy with my nicely running 10.5.6 Retail system by swapping kexts in and out of my extensions folder tweaking things into submission. What I guess I should be doing is tweaking the kexts in my EFI partition instead, leaving my system/library/extension folder virgin.(so future updates won't break my system)

 

So when you guys want to add or subtract kexts, how do you go about it?

 

 

Originally I used 'Chameleon DFE for hard disk', but I seem to remember adding other kexts after the fact once, and noticing I eventually ran out of room to add more. (In the extra folder). I probably kept the usual kexts in there, and was re-running chameleon while adding other kexts on top on the usual ones, and its as though it didn't know better than to sidestep the ones it already had installed and to just install the new ones. As a result each time I re-ran chameleon I lost a pile of available space.

 

 

Can I mount my EFI partition and review whats there and tweak the kext contents?

 

 

I hope this makes sense . . . :blink:

 

 

 

Joe

Link to comment
Share on other sites

I usually just drop to the Terminal and do:

sudo -s (BE CAREFUL!)

df -h (to see where the primary disk mounts - look for /) 

then: mkdir /Volumes/EFI

then: mount_hfs /dev/disk2s1 /Volumes/EFI

 

then I do what I need to do.

 

After I'm done I unmount the partition and reboot to see the effect.

 

The /Volumes/EFI directory is only a temporary name so it needs to be put in each time you do the work. You could make it visible and perm mounted in OSX, but I prefer the hard way.

Link to comment
Share on other sites

MoonScryer,

 

Nice .. thanks!

 

Here is what I obtained so far -

 

Filesystem	  Size   Used  Avail Capacity  Mounted on
/dev/disk0s2   200Gi   25Gi  174Gi	13%	/
devfs		  109Ki  109Ki	0Bi   100%	/dev
fdesc		  1.0Ki  1.0Ki	0Bi   100%	/dev
map -hosts	   0Bi	0Bi	0Bi   100%	/net
map auto_home	0Bi	0Bi	0Bi   100%	/home
/dev/disk0s3	32Gi   31Gi  1.8Gi	95%	/Volumes/MAC-DATA
/dev/disk1s1   3.9Gi  1.3Gi  2.6Gi	34%	/Volumes/FLASH_DRIVE

 

So does this mean I use /dev/disk0s2 ? Is that the EFI partition? It's my Leo partition @ 200Gi .. my EFI partition should be around 200mb, no?

 

 

Also, I'd like to make it permanently visible for now .. how does one go about that?

 

 

Thanks,

 

 

 

Joe

Link to comment
Share on other sites

I tried various mount points ... here are the results:

 

bash-3.2# df -h
Filesystem	  Size   Used  Avail Capacity  Mounted on
/dev/disk0s2   200Gi   28Gi  171Gi	15%	/
devfs		  114Ki  114Ki	0Bi   100%	/dev
fdesc		  1.0Ki  1.0Ki	0Bi   100%	/dev
/dev/disk0s3	32Gi   31Gi  1.8Gi	95%	/Volumes/MAC-DATA
map -hosts	   0Bi	0Bi	0Bi   100%	/net
map auto_home	0Bi	0Bi	0Bi   100%	/home
vfstool@fuse0   32Gi  3.1Gi   29Gi	10%	/private/tmp/651/C
bash-3.2# mkdir /Volumes/EFI
bash-3.2# mount_hfs /dev/disk0s1 /Volumes/EFI
mount_hfs: Invalid argument
bash-3.2# mount_hfs /dev/disk2s1 /Volumes/EFI
mount_hfs: No such file or directory
bash-3.2# mount_hfs /dev/disk0s2 /Volumes/EFI
mount_hfs: Resource busy
bash-3.2#

 

 

So I'm at a loss as to where mount the EFI partition ... :)

Link to comment
Share on other sites

What you actually need is the full diskid number for you current EFI partition, which the command "df -h" does not provide.

Use

diskutil list

instead. Look for the entry that contains your current OSX main partition. Notice that that drive will also contain an EFI partition. This is the one you need to use as a parameter for you mount command. Usually it's diskXs1, so in your case it would be "disk0s1". Now you can mount it with:

sudo su
mkdir /Volumes/EFI 
mount /dev/disk0s1 /Volumes/EFI

 

Good luck!

Link to comment
Share on other sites

hecker,

 

 

Thanks for the input. I tried this and got an error......but at last I can see my EFI partition; to point at it anyways *L*

 

Any idea what went wrong here ?

 

/dev/disk0
  #:					   TYPE NAME					SIZE	   IDENTIFIER
  0:	  GUID_partition_scheme						*232.9 Gi   disk0
  1:						EFI						 200.0 Mi   disk0s1
  2:				  Apple_HFS iLEOPARD				200.0 Gi   disk0s2
  3:				  Apple_HFS MAC-DATA				32.4 Gi	disk0s3
ileopards-cf-74gcdadbm:~ iNTELMAC$ sudo su
Password:
sh-3.2# mkdir /Volumes/EFI
sh-3.2# mount /dev/disk0s1 /Volumes/EFI
/dev/disk0s1 on /Volumes/EFI: Incorrect super block.

 

 

Joe

Link to comment
Share on other sites

Sorry, I didn't copy all the code. I actually did use sudo su as suggested at the beginning, as below:

 

ileopards-cf-74gcdadbm:~ iNTELMAC$ sudo su
Password:
sh-3.2# diskutil list
/dev/disk0
  #:					   TYPE NAME					SIZE	   IDENTIFIER
  0:	  GUID_partition_scheme						*232.9 Gi   disk0
  1:						EFI						 200.0 Mi   disk0s1
  2:				  Apple_HFS iLEOPARD				200.0 Gi   disk0s2
  3:				  Apple_HFS MAC-DATA				32.4 Gi	disk0s3
sh-3.2# mkdir /Volumes/EFI
sh-3.2# mount_hfs /dev/disk0s1 /Volumes/EFI
mount_hfs: Invalid argument

 

Anything we're overlooking?

 

 

Cheers,

 

Joe

Link to comment
Share on other sites

Fred,

 

I did everything as before and when I got to the invalid argument, I added the code you suggested. Here is what came back:

 

sh-3.2# fsck_hfs /dev/disk0s1
** /dev/rdisk0s1

 

After that I tried mounting again, and go the same invalid argument error.

 

 

 

Joe

Link to comment
Share on other sites

you have to unmonut the partition, then reboot and try again, with all steps:

umount /Volumes/EFI (If this fails, do umount -f /Volumes/EFI).

reboot and

 

 

mkdir /Volumes/EFI

mount_hfs /dev/diskXs1 /Volumes/EFI X=EFI drive)

killall Finder

 

if invalid argument try :

fsck_hfs /dev/disxXs1

Link to comment
Share on other sites

When I tried to umount, it said /Volumes/EFI was not mounted, so I rebooted and did the following:

 

ileopards-cf-74gcdadbm:~ iNTELMAC$ sudo su
Password:
sh-3.2# mkdir /Volumes/EFI
sh-3.2# mount_hfs /dev/disk0s1 /Volumes/EFI
mount_hfs: Invalid argument
sh-3.2# 
sh-3.2# 
sh-3.2# fsck_hfs /dev/disk0s1
** /dev/rdisk0s1
sh-3.2# killall Finder
sh-3.2#

 

 

I watched as Finder disappeared off my dock...

 

So tried:

 

cd /Volumes/EFI
ls

 

..and got no results.

 

 

Then my Finder reappeared, but I do not see my EFI partition yet.

 

 

Hard nut to crack ..

 

 

Joe

Link to comment
Share on other sites

You have to do step by step on each boot because the number of the disk and partition can changes.

so

 

1) Open Terminal

 

2) sudo -s (and type in your password)

 

3) diskutil info / | grep Identifier - this tells you the values for diskXsY for '/', which is the currently-booted system. (If you're doing this on a disk other than the one you've booted from, you need to modify accordingly.)

 

4) diskutil list - diskXs1 should be called EFI. this is the hidden EFI partition on your target drive.

then the rest of the steps

Link to comment
Share on other sites

I've gotten lazy with my nicely running 10.5.6 Retail system by swapping kexts in and out of my extensions folder tweaking things into submission. What I guess I should be doing is tweaking the kexts in my EFI partition instead, leaving my system/library/extension folder virgin.(so future updates won't break my system)

 

So when you guys want to add or subtract kexts, how do you go about it?

Originally I used 'Chameleon DFE for hard disk', but I seem to remember adding other kexts after the fact once, and noticing I eventually ran out of room to add more. (In the extra folder). I probably kept the usual kexts in there, and was re-running chameleon while adding other kexts on top on the usual ones, and its as though it didn't know better than to sidestep the ones it already had installed and to just install the new ones. As a result each time I re-ran chameleon I lost a pile of available space.

Can I mount my EFI partition and review whats there and tweak the kext contents?

I hope this makes sense . . . :(

Joe

here is my terminal output if it helps any;

 

sudo -s

Password:

bash-3.2# mkdir /Volumes/EFI

bash-3.2# diskutil list

.....

/dev/disk3

#: TYPE NAME SIZE IDENTIFIER

0: GUID_partition_scheme *372.6 Gi disk3

1: EFI 200.0 Mi disk3s1

2: Apple_HFS Macintosh HD 372.3 Gi disk3s2

......

bash-3.2# mount_hfs /dev/disk3s1 /Volumes/EFI

bash-3.2# cd /Volumes/EFI

bash-3.2# ls

.fseventsd Extensions System dsdt.aml update.sh

Disabled Library boot update.log

bash-3.2# cd ..

bash-3.2# umount EFI

bash-3.2# rmdir EFI

bash-3.2#

 

Unless something weird is going on, you should be able to do the same

 

Also, here is the output when i fsck_hfs my EFI partition;

 

bash-3.2# fsck_hfs /dev/disk3s1

** /dev/rdisk3s1

** Checking Non-journaled HFS Plus volume.

** Checking Extents Overflow file.

** Checking Catalog file.

** Checking multi-linked files.

** Checking Catalog hierarchy.

** Checking Extended Attributes file.

** Checking volume bitmap.

** Checking volume information.

** The volume EFI appears to be OK.

bash-3.2#

 

Does your output look the same? If not, something fishy is going on with your HD....

Link to comment
Share on other sites

sh-3.2# diskutil info / |grep Identifier
  Device Identifier:		disk0s2
sh-3.2# diskutil list
/dev/disk0
  #:					   TYPE NAME					SIZE	   IDENTIFIER
  0:	  GUID_partition_scheme						*232.9 Gi   disk0
  1:						EFI						 200.0 Mi   disk0s1
  2:				  Apple_HFS iLEOPARD				200.0 Gi   disk0s2
  3:				  Apple_HFS MAC-DATA				32.4 Gi	disk0s3
sh-3.2#

 

No matter what my EFI partition is disk0s1, yet I always get the invalid argument error...

 

 

So I guess I should refocus on WHY I keep getting the invalid argument. Perhaps a symptom of something larger than this exercise??

 

 

Wierd..

 

 

Joe

 

 

 

sh-3.2# fsck_hfs /dev/disk0s1
** /dev/rdisk0s1
sh-3.2#

 

 

This is the ONLY data I get back on the fsck command. Might shed light on the issue I hope

 

 

Joe

Link to comment
Share on other sites

sh-3.2# diskutil info / |grep Identifier
  Device Identifier:		disk0s2
sh-3.2# diskutil list
/dev/disk0
  #:					   TYPE NAME					SIZE	   IDENTIFIER
  0:	  GUID_partition_scheme						*232.9 Gi   disk0
  1:						EFI						 200.0 Mi   disk0s1
  2:				  Apple_HFS iLEOPARD				200.0 Gi   disk0s2
  3:				  Apple_HFS MAC-DATA				32.4 Gi	disk0s3
sh-3.2#

 

No matter what my EFI partition is disk0s1, yet I always get the invalid argument error...

So I guess I should refocus on WHY I keep getting the invalid argument. Perhaps a symptom of something larger than this exercise??

Wierd..

Joe

sh-3.2# fsck_hfs /dev/disk0s1
** /dev/rdisk0s1
sh-3.2#

This is the ONLY data I get back on the fsck command. Might shed light on the issue I hope

Joe

 

In case you didn't see my PM yet, did you use the "munky" DFE install method? If not, that explains everything. I will dig out the thread here in a second and send you the link. I believe your EFI partition is blank at the moment (ie, unused) and that explains everything. Following the "munky" method is very simple...thread link will be coming shortly....

 

here is link;

 

http://forum.insanelymac.com/index.php?showtopic=127330

Link to comment
Share on other sites

In case you didn't see my PM yet, did you use the "munky" DFE install method? If not, that explains everything. I will dig out the thread here in a second and send you the link. I believe your EFI partition is blank at the moment (ie, unused) and that explains everything. Following the "munky" method is very simple...thread link will be coming shortly....

 

here is link;

 

http://forum.insanelymac.com/index.php?showtopic=127330

 

 

:)

 

Opps. Ok .... I'll dive into that article, and hopefully later today I can get that done so I can begin returning ,my extensions folder to stock.

 

 

Good catch og_phantom!

 

 

Joe

Link to comment
Share on other sites

:)

 

Opps. Ok .... I'll dive into that article, and hopefully later today I can get that done so I can begin returning ,my extensions folder to stock.

Good catch og_phantom!

Joe

No problem!!! Just as in the PM I sent you, ask the question (in that thread) about replacing the DFE bootloader and using the efiv6.1 from munky (without doing a re-install). I believe it can be done painlessly, but ask just in case. I don't want to be the cause of you losing all your data!!! :)

Link to comment
Share on other sites

Excellent, I'll ask on that linked thread. This will definately get me on the right track. I'm really looking forward to cleaning things up, and tweaking my system via the EFI partition with kexts, boot.plist, and EFI strings etc .. and NOT my /system/extensions folder.

 

 

Seems like a much cleaner approach to building a more solid, bombproof system.

 

 

Thanks for all the input guys. Your earlier comments would have worked if I had already applied the Munky approach.

 

 

*off to study, question, and attempt it*

 

 

I'll report back once I'm there.

 

 

 

*beer*

 

 

 

Joe

Link to comment
Share on other sites

In case you didn't see my PM yet, did you use the "munky" DFE install method? If not, that explains everything. I will dig out the thread here in a second and send you the link. I believe your EFI partition is blank at the moment (ie, unused) and that explains everything. Following the "munky" method is very simple...thread link will be coming shortly....

 

here is link;

 

http://forum.insanelymac.com/index.php?showtopic=127330

 

Wo could try to help you for eternity !! :D

Link to comment
Share on other sites

Wo could try to help you for eternity !! :)

 

 

Good one ..

 

 

I guess I scanned Munky's primer too quickly a few weeks back, and made a huge assumption. I assumed that installing as I had, and then applying the DFE for hard disk was placing the kexts in the EFI partition as well. I figured they were two ways to the same end ..

 

 

Joe

Link to comment
Share on other sites

  • 1 month later...

Hello all,

 

I am in exactly the same boat as "CF-74 ToughMac" was, and I have some questions:

 

- I installed vanilla 10.5.6 then used PCWiz's Universal Installer to install PC_EFIv9. Being somewhat of a n00b, I'm still unclear about the EFI partition, and where my EFI resident kext files are supposed to be.

 

Originally, many, many moons and installs ago, I was using the Munky method, unitl I discovered I could just use PCWiz's utilities to install PC_EFIv9. Now, as CF-74, I can't get /Volumes/EFI to mount, as when I was using Munky. I now see from this thread there is a reason for this, but I don't know what that reason is. Explanation?

 

Also, when I look in /Extra, there is nothing in there either. Using PCWiz's utilities, such as UOI and "OSx86 Tools", changes made through those utilities are implemented and work (I have a very elaborate system, and it is working VERY well at this point). Question: So, where ARE my EFI files under this configuration? What do I need to do to interact with them at this point? Any file management tips you could share with me would really be helpful.

 

Like "CF-74 ToughMac", I want to start running a very clean, well managed system to avoid future problems. In order to do this, I need a clear understanding of where things are, and how to interact with them.

 

Thank you all very much, I so appreciate all of you in the OSx86 community who are so kind and generous enough to share your invaluable talents with us mere n00bs. :D

 

Mammoth

Link to comment
Share on other sites

  • 1 year later...

For those with the 'invalid argument' issue, the drive with the EFI partition cannot be mounted if you are trying to do it from, say, another OS X installation. You must force the target drive to be unmounted before you can mount the EFI partition.

For example, I am on my Leopard install, and want to mount the EFI partition of my new Snow Leo installation that's on a separate drive.

 

first, use 'diskutil list' command to discover the correct 'identifier' for the EFI partition:

 

		 diskutil list


	   /dev/disk3
		#:					   TYPE NAME					SIZE	   IDENTIFIER
		0:	  GUID_partition_scheme						*465.8 Gi   disk3
		1:						EFI						 200.0 Mi   disk3s1
		2:				  Apple_HFS SnowLeo				 465.4 Gi   disk3s2

 

 

Replace SnowLeo and disk3s1 in the commands below with your info obtained from the output of 'diskutil list' above.

 

		   sudo umount -f /Volumes/SnowLeo
	   mkdir /Volumes/EFI
	   sudo mount_hfs /dev/disk3s1 /Volumes/EFI
	   killall Finder

 

 

That's it. Hope this helps someone else!

Happy Hackintoshing!

Link to comment
Share on other sites

 Share

×
×
  • Create New...