User avatar
grynnan
Posts: 15
Joined: Mon May 14, 2012 3:53 pm
Contact: ICQ Website

img

Fri Jul 20, 2012 10:04 pm

Not really a request, more of a "Request of a guideline to follow for linux dist".

SD image:
[ FAT32 (*1)] [SWAP (2*)] [ext4 Linux (3*)]

1* FAT32 "Windows Standard" as in not FAT16 with custom cluster size and other wierdness just because you are a geek and want to show off.

2* Swap, used or not, it should be located after first (FAT32) Partition.

3* Here be Linux

Well, that's what I expect and I think most users wants, but we seldom see.

aaa801
Posts: 428
Joined: Mon Jun 04, 2012 9:06 pm
Location: Berkshire

Re: img

Fri Jul 20, 2012 10:43 pm

Aint going to see it with our android build :D

User avatar
grynnan
Posts: 15
Joined: Mon May 14, 2012 3:53 pm
Contact: ICQ Website

Re: img

Sat Jul 21, 2012 12:39 am

Well, I didn't even know anyone was trying to make a Android dist.
Cyanogen has been looking at it, but that was about it.

Still, would like to see that the dists. located under "downloads" to follow these guidelines. :D

User avatar
AndrewS
Posts: 3625
Joined: Sun Apr 22, 2012 4:50 pm
Location: Cambridge, UK
Contact: Website

Re: img

Sat Jul 21, 2012 6:40 am

What difference does it make, out of interest?

I believe on the latest distros there isn't a swap partition, but you can enable a swapfile in the Linux partition.

aaa801
Posts: 428
Joined: Mon Jun 04, 2012 9:06 pm
Location: Berkshire

Re: img

Sun Jul 22, 2012 6:43 pm

grynnan wrote:Well, I didn't even know anyone was trying to make a Android dist.
Cyanogen has been looking at it, but that was about it.

Still, would like to see that the dists. located under "downloads" to follow these guidelines. :D
yer i mean its not like theres a 7 page thread about it and already working images you know..

User avatar
grynnan
Posts: 15
Joined: Mon May 14, 2012 3:53 pm
Contact: ICQ Website

Re: img

Mon Jul 23, 2012 12:57 pm

Code: Select all

The following is a table of logical drive sizes, FAT (File Allocation Table) types, and cluster sizes:

                  Drive Size      FAT Type     Sectors     Cluster
               (logical volume)              Per Cluster     Size
               ----------------   --------   -----------   -------
(Floppy Disks)      360K           12-bit         2         1K
                    720K           12-bit         2         1K
                   1.2 MB          12-bit         1       512 bytes
                   1.44 MB         12-bit         1       512 bytes
                   2.88 MB         12-bit         2         1K
(Hard Disks)     0 MB - 15 MB      12-bit         8         4K
                16 MB - 127 MB     16-bit         4         2K
               128 MB - 255 MB     16-bit         8         4K
               256 MB - 511 MB     16-bit        16         8K
               512 MB - 1023 MB    16-bit        32        16K
              1024 MB - 2047 MB    16-bit        64        32K

File name 8.3				
FAT32, and you are not limited to 8.3 names, nor are you affected by weird errors that might happen if using FAT16 as of the current Raspian's BOOT partitions cluster size.

User avatar
AndrewS
Posts: 3625
Joined: Sun Apr 22, 2012 4:50 pm
Location: Cambridge, UK
Contact: Website

Re: img

Tue Jul 24, 2012 10:09 am

Could you explain more about these "weird errors"? I wonder if they might have anything to do with the /boot filesystem corruption some people are getting :?:

The /boot partition (specifically bootcode.bin) has to be read by the embedded-in-GPU firmware, which obviously can't be changed, so I dunno if that places certain restrictions on what filesystem setups on /boot will or won't work? :|

User avatar
grynnan
Posts: 15
Joined: Mon May 14, 2012 3:53 pm
Contact: ICQ Website

Re: img

Tue Jul 24, 2012 10:57 pm

I will try to look deeper into it. One though is buffer issues, but..nah.. I'll keep checking..
I've also noticed that, and other "weird things". My config.txt looked like my cat did it.
( I don't mind her being interested of the Pi, but I'm afraid her expertise in the area are a bit limited. However, this time I can't blame her. =^.^= )

I reformatted it to FAT32 4k (4 096 bytes in each allocation unit.) . put the files from 0.fat and my backup of config.txt into it, and it works like a charm.
( /0.fat/ , from inside the 2012-07-15-wheezy-raspbian.img)

User avatar
grynnan
Posts: 15
Joined: Mon May 14, 2012 3:53 pm
Contact: ICQ Website

Re: img

Wed Jul 25, 2012 9:59 pm

Thinking of testing a little thing. By using a python3 script to find all primes till 100k (that would be 9591 prime numbers), writing those to a file onto the /boot.

If it's a buffer issue, there would most likely be a random letter or such here and there. But it will be a regular pattern, like every 17th line have a "!" or something like it in it.

If it is a partition issue, the file will have some major flaws.

Now, I don't have the time to do this. But I have the. py script ready.

Code: Select all

 # Generate prime numbers
# Based on an article from http://dunningrb.wordpress.com/

import datetime, sys, math

# Function to print message
def print_prime(x):
  print (" Prime : %7i " %x)

# Function to search for prime numbers
# within number range
def find_primes(upper_limit):
  count = 0
  candidate = 3
  while(candidate <= upper_limit):
    trial_divisor = 2
    prime = 1 # assume it's prime
    while(trial_divisor**2 <= candidate and prime):
      if(candidate%trial_divisor == 0):
        prime = 0 # it isn't prime
      trial_divisor+=1
    if(prime):
      print_prime(candidate)
      count += 1
    candidate += 2
  return count
# Check if the script was called with a
# parameter. Use that as the upper limit
# of numbers to search
if len(sys.argv) != 2:
  upper_limit=1000000
else:
  upper_limit=int(sys.argv[1])

# Record the current time
startTime = datetime.datetime.now()

# Start the process
print ("")
print ("Starting ...")
print ("")
count = find_primes(upper_limit)
print ("")

# Measure and print the elapsed time
elapsed=datetime.datetime.now()-startTime
print (" Found %d primes in %s" %(count,elapsed))
print ("")
 
Made this as a simple benchmark, and i will go to 1 milion, so use this in terminal.

Code: Select all

$ python filename.py 100000
uh where "filename" is what ever u call it. lol, sorry but I had to write that, who knows, might be an American reading this.

The script doesn't as you see write anything into a (txt?) file as such, but I guess you know how.

Now I'm off to Stockholm's northen archipelago.

User avatar
grynnan
Posts: 15
Joined: Mon May 14, 2012 3:53 pm
Contact: ICQ Website

Re: img

Sat Jul 28, 2012 1:04 pm

After some testing, the conclusion.

1. Boot should be in 4k cluster FAT32
2. No Swap. (Shouldn't be used on any solid-state memory devices)


FAT16 simply doesn't work as it should on Pi. Major read and write issues, regardless of SD size or brand.

So if you don't want some issues, backup the content on the Boot partition, reformat it to FAT32 4k clusters, put back backed up files.

Return to “General discussion”