New IT forum
13 August 2022, 12:02:23 pm *
Welcome, %1$s. Please login or register.

: MiraBox now in stock.
 
Pages: [1] 2 3

Author Topic: "Bus error" from vim on Dreamplug  (Read 36158 times)

craigmcfly

  • Newbie
  • *
  • Posts: 11
"Bus error" from vim on Dreamplug
« on: 21 April 2011, 10:46:16 pm »

Hi all,

Got the dreamplug and pbx-to-be this morning and love it. Sorry, if I've missed an existing thread, however - I installed vim and a few other bits and bobs and rebooted. I was then surprised to see

[email protected]:~# vim /var/log/messages
Bus error

[email protected]:/etc/asterisk# vim cdr_mysql.conf
Bus error

coupled with the appearance of

Apr 21 22:38:50 ubuntu kernel: attempt to access beyond end of device
Apr 21 22:38:50 ubuntu kernel: sda2: rw=0, want=3650856, limit=3634038
Apr 21 22:38:50 ubuntu kernel: attempt to access beyond end of device
Apr 21 22:38:50 ubuntu kernel: sda2: rw=0, want=3650856, limit=3634038

A reboot with /forcefsck created had no effect. Is this just a bad package in the repo or should I be more concerned?

When I removed vim and went back to standard vi everything was fine again.

Advice welcome :)

Cheers,

Craig
Logged

craigmcfly

  • Newbie
  • *
  • Posts: 11
Re: "Bus error" from vim on Dreamplug
« Reply #1 on: 21 April 2011, 11:20:07 pm »

Okay, so after a bit more digging, ldconfig is throwing the same error which makes me nervous. Every time I get it, I see

Apr 21 23:19:32 ubuntu kernel: attempt to access beyond end of device
Apr 21 23:19:32 ubuntu kernel: sda2: rw=0, want=3635352, limit=3634038

appear in the logs.
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: "Bus error" from vim on Dreamplug
« Reply #2 on: 22 April 2011, 10:51:03 am »

I'm not getting any of the error messages that you are reporting.

I interpret those errors as issues with the filesystem (on the microSD card), not as problems with any packages. I think you've come to the same conclusion.

Does /forcefsck produce a log? Could you remove the microSD card and fsck it in another device? I also wonder if reseating the card might help. If fsck runs and doesn't make any fixes or produce any output, and the problem is intermittent, I'd be inclined to check the seating and cables. Of course I'd expect to see many more errors in such a case, also.
Logged

odomok

  • Newbie
  • *
  • Posts: 5
Re: "Bus error" from vim on Dreamplug
« Reply #3 on: 22 April 2011, 12:46:49 pm »

Hi All,

Can I add my problem to this thread please?

Also got the Dreamplug yesterday, great little machine, but I have the 'same' bus error.

I was installing a fair number of packages, one of which was MySQL where I had to --purge and reinstall several times because the /tmp directory was not writeable by the mysql user and also the installation gave root ownership of the /var/lib/mysql/mysql (the main database) files.

Shortly after successfully overcoming this, I tried installing ubuntu-restricted-extras.  The installation contains a large number of libraries, and crashed towards the end with 'bus error'  I could be specific about the packages concerned, but I think that would be a red herring.  I tried running  debsums -s -a 2 and got a large number of errors.
Code: [Select]
debsums: checksum mismatch alsa-base file /etc/modprobe.d/alsa-base.conf
debsums: no md5sums for binutils
debsums: no md5sums for bzip2
debsums: checksum mismatch debsums file /etc/default/debsums
debsums: can't open dictionaries-common file /usr/lib/ispell/README.select-ispell (No such file or directory)
debsums: can't open dictionaries-common file /usr/lib/emacsen-common/packages/install/dictionaries-common (No such file or directory)
debsums: can't open dictionaries-common file /usr/lib/emacsen-common/packages/remove/dictionaries-common (No such file or directory)
debsums: can't check dictionaries-common file /usr/share/perl5/Debian/DictionariesCommon.pm (Input/output error)
debsums: can't check fontconfig file /usr/share/defoma/scripts/fontconfig.defoma (Input/output error)
debsums: can't open gconf2-common file /usr/share/sgml/gconf/gconf-1.0.dtd (No such file or directory)
debsums: no md5sums for initscripts
debsums: no md5sums for joe
debsums: no md5sums for klogd
debsums: can't check libatk1.0-0 file /usr/lib/libatk-1.0.so.0.2609.1 (Input/output error)
debsums: no md5sums for libbz2-1.0
debsums: can't check libcairo2 file /usr/lib/libcairo.so.2.10800.6 (Input/output error)
debsums: can't check libdatrie0 file /usr/lib/libdatrie.so.0.0.3 (Input/output error)
debsums: can't open libdatrie0 file /usr/share/doc/libdatrie0/changelog.Debian.gz (No such file or directory)
debsums: can't open libdatrie0 file /usr/share/doc/libdatrie0/changelog.gz (No such file or directory)
debsums: can't open libdatrie0 file /usr/share/doc/libdatrie0/copyright (No such file or directory)
debsums: can't open libdatrie0 file /usr/share/doc/libdatrie0/NEWS.gz (No such file or directory)
debsums: can't open libdatrie0 file /usr/share/doc/libdatrie0/README (No such file or directory)
debsums: no md5sums for libdb4.2
debsums: can't check libdrm2 file /usr/lib/libdrm.so.2.4.0 (Input/output error)
debsums: can't check libgconf2-4 file /usr/lib/libgconf-2.so.4.1.5 (Input/output error)
debsums: can't open libgconf2-4 file /usr/lib/libgconf2-4/gconfd-2 (No such file or directory)
debsums: can't open libgconf2-4 file /usr/lib/libgconf2-4/gconf-defaults-mechanism (No such file or directory)
debsums: can't open libgconf2-4 file /usr/lib/libgconf2-4/gconf-sanity-check-2 (No such file or directory)
debsums: can't open libgconf2-4 file /usr/lib/libgconf2-4/2/libgconfbackend-oldxml.so (No such file or directory)
debsums: can't open libgconf2-4 file /usr/lib/libgconf2-4/2/libgconfbackend-xml.so (No such file or directory)
debsums: can't open libgconf2-4 file /usr/lib/libgconf2-4/2/libgconfbackend-evoldap.so (No such file or directory)
debsums: no md5sums for libgdbm3
debsums: can't check libgl1-mesa-glx file /usr/lib/libGL.so.1.2 (Input/output error)
debsums: can't check libglu1-mesa file /usr/lib/libGLU.so.1.3.070300 (Input/output error)
debsums: can't check libgp11-0 file /usr/lib/libgp11.so.0.0.0 (Input/output error)
debsums: can't open libgtk2.0-0 file /usr/share/doc/libgtk2.0-0/copyright (No such file or directory)
debsums: can't open libgtk2.0-0 file /usr/share/doc/libgtk2.0-0/changelog.gz (No such file or directory)
debsums: can't open libgtk2.0-0 file /usr/share/doc/libgtk2.0-0/changelog.Debian.gz (No such file or directory)
debsums: can't open libgtk2.0-0 file /usr/share/doc/libgtk2.0-0/README.Debian (No such file or directory)
debsums: can't open libgtk2.0-0 file /usr/lib/libgtk2.0-0/gtk-update-icon-cache (No such file or directory)
debsums: can't open libgtk2.0-0 file /usr/lib/libgtk2.0-0/update-gdkpixbuf-loaders (No such file or directory)
debsums: can't open libgtk2.0-0 file /usr/lib/libgtk2.0-0/update-gtk-immodules (No such file or directory)

etc etc etc

/var/log/messages gives:
Code: [Select]
Apr 22 10:46:11 ubuntu kernel: sda2: rw=0, want=3641640, limit=3634038
Apr 22 10:46:11 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:11 ubuntu kernel: sda2: rw=0, want=3637160, limit=3634038
Apr 22 10:46:11 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:11 ubuntu kernel: sda2: rw=0, want=3637136, limit=3634038
Apr 22 10:46:11 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:11 ubuntu kernel: sda2: rw=0, want=3636000, limit=3634038
Apr 22 10:46:11 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:11 ubuntu kernel: sda2: rw=0, want=3635976, limit=3634038
Apr 22 10:46:33 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:33 ubuntu kernel: sda2: rw=0, want=3635472, limit=3634038
Apr 22 10:46:33 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:33 ubuntu kernel: sda2: rw=0, want=3635472, limit=3634038
Apr 22 10:46:33 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:33 ubuntu kernel: sda2: rw=0, want=3634216, limit=3634038
Apr 22 10:46:33 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:33 ubuntu kernel: sda2: rw=0, want=3634232, limit=3634038
Apr 22 10:46:33 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:33 ubuntu kernel: sda2: rw=0, want=3634472, limit=3634038
Apr 22 10:46:33 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:33 ubuntu kernel: sda2: rw=0, want=3634488, limit=3634038
Apr 22 10:46:33 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:33 ubuntu kernel: sda2: rw=0, want=3634040, limit=3634038
Apr 22 10:46:34 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:34 ubuntu kernel: sda2: rw=0, want=3635464, limit=3634038
Apr 22 10:46:34 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:34 ubuntu kernel: sda2: rw=0, want=3635464, limit=3634038
Apr 22 10:46:51 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:51 ubuntu kernel: sda2: rw=0, want=3635504, limit=3634038
Apr 22 10:46:51 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:46:51 ubuntu kernel: sda2: rw=0, want=3635480, limit=3634038
Apr 22 10:53:55 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:53:55 ubuntu kernel: sda2: rw=0, want=3635880, limit=3634038
Apr 22 10:53:55 ubuntu kernel: attempt to access beyond end of device
Apr 22 10:53:55 ubuntu kernel: sda2: rw=0, want=3635856, limit=3634038

etc etc

df gives:
Code: [Select]
Filesystem           1K-blocks      Used Available Use% Mounted on
tmpfs                   256888         0    256888   0% /lib/init/rw
varrun                  256888        84    256804   1% /var/run
varlock                 256888         0    256888   0% /var/lock
udev                    256888       140    256748   1% /dev
tmpfs                   256888         0    256888   0% /dev/shm
rootfs                 1797984   1350704    355948  80% /

It appears at first glance that the culprit is possibly the microsd card but I could do with some pointers.

Thanks

Ian
Logged

odomok

  • Newbie
  • *
  • Posts: 5
Re: "Bus error" from vim on Dreamplug
« Reply #4 on: 22 April 2011, 05:13:21 pm »

This output from dmesg is probably relevant...
Code: [Select]
scsi 0:0:0:0: Direct-Access     Generic  STORAGE DEVICE   9910 PQ: 0 ANSI: 0
sd 0:0:0:0: Attached scsi generic sg0 type 0
scsi 0:0:0:1: Direct-Access     Generic  STORAGE DEVICE   9910 PQ: 0 ANSI: 0
sd 0:0:0:0: [sda] 3842048 512-byte logical blocks: (1.96 GB/1.83 GiB)
sd 0:0:0:1: Attached scsi generic sg1 type 0
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Mode Sense: 0b 00 00 08
sd 0:0:0:0: [sda] Assuming drive cache: write through
sd 0:0:0:1: [sdb] 7829504 512-byte logical blocks: (4.00 GB/3.73 GiB)
sd 0:0:0:1: [sdb] Write Protect is off
sd 0:0:0:1: [sdb] Mode Sense: 0b 00 00 08
sd 0:0:0:1: [sdb] Assuming drive cache: write through
sd 0:0:0:0: [sda] Assuming drive cache: write through
 sda: sda1 sda2
sda: p2 size 3653412 exceeds device capacity, limited to end of disk
sd 0:0:0:1: [sdb] Assuming drive cache: write through
 sdb:
sd 0:0:0:0: [sda] Assuming drive cache: write through
sd 0:0:0:0: [sda] Attached SCSI removable disk
 sdb1
sd 0:0:0:1: [sdb] Assuming drive cache: write through
sd 0:0:0:1: [sdb] Attached SCSI removable disk
EXT3-fs (sda2): warning: mounting fs with errors, running e2fsck is recommended
Note the 'sda: p2 size 3653412 exceeds device capacity, limited to end of disk'

Cheers

Ian
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: "Bus error" from vim on Dreamplug
« Reply #5 on: 22 April 2011, 05:26:59 pm »

I think that the solution will involve opening the Dreamplug case in order to get at the micro-SD card. Do you have a means of re-writing the SD card with the official rootfs, or access to another (2G+) micro-SD card?
« Last Edit: 22 April 2011, 07:35:20 pm by NewIT_Marcus »
Logged

Fletch

  • Guest
Re: "Bus error" from vim on Dreamplug
« Reply #6 on: 22 April 2011, 06:41:52 pm »

I think that the solution will involve opening the Dreamplug case in order to get at the micro-SD card. Do you have a means of re-writing the SD card with the official roots, or access to another (2G+) micro-SD card?

You could probably boot from a USB or external SD and use that to write a new rootfs to the internal uSD.  I haven't tried it though.  Opening the case is pretty simple.
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: "Bus error" from vim on Dreamplug
« Reply #7 on: 22 April 2011, 07:37:22 pm »

Opening the case is pretty simple.

Yes, however ...

You could probably boot from a USB or external SD and use that to write a new rootfs to the internal uSD.

this isn't; a JTAG is required to get at U-Boot / environment variables. Easiest tests are changes to the micro-SD card.

Logged

Fletch

  • Guest
Re: "Bus error" from vim on Dreamplug
« Reply #8 on: 22 April 2011, 08:08:39 pm »

a JTAG is required to get at U-Boot / environment variables. Easiest tests are changes to the micro-SD card.

Good point.  If you don't have a JTAG module, you have to remove the uSD and copy the rootfs over on your computer.
Logged

craigmcfly

  • Newbie
  • *
  • Posts: 11
Re: "Bus error" from vim on Dreamplug
« Reply #9 on: 23 April 2011, 10:15:41 am »

Hi chaps,

You're all being extremely helpful. It's much appreciated. I'm away for the easter weekend at the mo but I'll see if I can open the case up and get at the microSD.

My suspicions about there being a problem with the underlying disk have been extended by the fact that when I ran fdisk -l on the internal disk it threw up an error that the partition table went beyond the disk and the partition start/end numbers didn't make sense.

I'll let you know how I get on.

Cheers,

Craig
Logged

craigmcfly

  • Newbie
  • *
  • Posts: 11
Re: "Bus error" from vim on Dreamplug
« Reply #10 on: 23 April 2011, 04:32:51 pm »

Hi all,

How does the micro SD remove from the board? It seems to be clipped in somehow, but I can't quite work it out.

Cheers,

Craig
Logged

Fletch

  • Guest
Re: "Bus error" from vim on Dreamplug
« Reply #11 on: 23 April 2011, 04:54:05 pm »

Hi all,

How does the micro SD remove from the board? It seems to be clipped in somehow, but I can't quite work it out.

Cheers,

Craig

The metal clip slides - I forget which way.  Use your fingernail on the ridge on top and it will slide in one direction to unlock.  Then flip open.
Logged

craigmcfly

  • Newbie
  • *
  • Posts: 11
Re: "Bus error" from vim on Dreamplug
« Reply #12 on: 23 April 2011, 07:30:19 pm »

Got to the card. Much obliged. However, it goes downhill from there:

Quote

[email protected]:/dev# fsck /dev/sdb1
fsck from util-linux-ng 2.17.2
dosfsck 3.0.9, 31 Jan 2010, FAT32, LFN
Seek to 1967128064:Invalid argument

[email protected]:/dev# fsck /dev/sdb2
fsck from util-linux-ng 2.17.2
e2fsck 1.41.12 (17-May-2010)
The filesystem size (according to the superblock) is 456676 blocks
The physical size of the device is 454254 blocks
Either the superblock or the partition table is likely to be corrupt!
Abort<y>? yes

I decided to plow on with sdb2 and tried to repair it and it didn't help. Parted is still throwing the same error that the partition extends beyond the end of the device. Is there a guide online for how I need to arrange the partitions for the Ubuntu install? I don't trust the partition sizes Ubuntu tells me
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: "Bus error" from vim on Dreamplug
« Reply #13 on: 24 April 2011, 08:29:00 pm »

How does the micro SD remove from the board? It seems to be clipped in somehow, but I can't quite work it out.

I posted an illustration here
Logged

NewIT_Marcus

  • Hero Member
  • *****
  • Posts: 960
Re: "Bus error" from vim on Dreamplug
« Reply #14 on: 24 April 2011, 08:48:04 pm »

Got to the card. Much obliged. However, it goes downhill from there:

Quote

[email protected]:/dev# fsck /dev/sdb1
fsck from util-linux-ng 2.17.2
dosfsck 3.0.9, 31 Jan 2010, FAT32, LFN
Seek to 1967128064:Invalid argument

[email protected]:/dev# fsck /dev/sdb2
fsck from util-linux-ng 2.17.2
e2fsck 1.41.12 (17-May-2010)
The filesystem size (according to the superblock) is 456676 blocks
The physical size of the device is 454254 blocks
Either the superblock or the partition table is likely to be corrupt!
Abort<y>? yes

I decided to plow on with sdb2 and tried to repair it and it didn't help. Parted is still throwing the same error that the partition extends beyond the end of the device. Is there a guide online for how I need to arrange the partitions for the Ubuntu install? I don't trust the partition sizes Ubuntu tells me

I have done some work on copying (cloning) a virgin, ex-factory micro-SD card. On my first attempt (inserting the micro-SD card in an adapter, in to the SD card slot of another Dreamplug), I saw errors that described some subdirectories as being unreadable.

When I placed the micro-SD card (in its adapter) into the SD card slot in a Sheevaplug, it became readable.

I continue to have suspicion about the seating of the card and / or the cable. There is a short length of 5-strand cabling that joins the micro-SD card board to the main board. Now that I have copied the micro-SD card, I can re-assemble the Dreamplugs and fire them up. I think that the seating is worth double-checking.

The micro-SD card that I copied showed 1,967,128,576 bytes when I used dd:

Code: [Select]
dd if=/dev/mmcblk0 of=ex-factory-2011-04-24/ex-factory-2011-04-24-microSD.img bs=10M
187+1 records in
187+1 records out
1967128576 bytes (2.0 GB) copied, 132.573 s, 14.8 MB/s

I've removed references to external storage in the following output, leaving only the (micro)SD card stuff. The error message is interesting:

Code: [Select]
# fdisk -l

Disk /dev/mmcblk0: 1967 MB, 1967128576 bytes
62 heads, 61 sectors/track, 1015 cylinders
Units = cylinders of 3782 * 512 = 1936384 bytes
Disk identifier: 0x00000000

        Device Boot      Start         End      Blocks   Id  System
/dev/mmcblk0p1               1        1016     1920993+   6  FAT16
Partition 1 has different physical/logical endings:
     phys=(54, 61, 61) logical=(1015, 54, 24)
/dev/mmcblk0p2              56        1021     1826706   83  Linux


Code: [Select]
# mount -l | grep mmc
/dev/mmcblk0p2 on /mnt/mmc-rootfs-partition type ext3 (rw) [dreamv7_fs]
/dev/mmcblk0p1 on /mnt/mmc-kernel-partition type msdos (rw)


I have a (315M) image for the entire micro-SD card, plus a separate 310M file with the rootfs (compressed). The kernel partition is the most easily described (and / or recreated); it should contain only the 2.6M uImage (and possibly a lost+found directory, or maybe that was created when I mounted it).

I'll be uploading the files asap, but that might mean overnight.


(edited to remove crud from fdisk output)
« Last Edit: 25 April 2011, 11:17:12 am by NewIT_Marcus »
Logged
Pages: [1] 2 3
 
 

Powered by MySQL Powered by PHP SMF 2.0.10 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!