Re: UEFI + Raid

2017-05-10 Thread Pascal Hambourg

Le 11/05/2017 à 00:53, Sam Smith a écrit :

On 05/09/2017 05:44 PM, Pascal Hambourg wrote:


Or use grub-install with --removable and --efi-directory for each disk.
Or use grub-install with --efi-directory and --bootloader-id to install
a copy of GRUB wherever you want and add an EFI boot entry for it.

(...)

I tried to use "grub-install -v  --target=x86_64-efi
--bootloader-id=grub /dev/sdb"

But as far as I could tell everything was installed to the first disk
still (sda) and /boot/efi/EFI/ then had two entries, the old 'debian'
one and then new 'grub' one.


With EFI targets, grub-install ignores the specified device, because it 
is irrelevant. This i why I told to use --efi-directory to indicate 
which EFI partition (mounted on the specified directory instead of 
/boot/efi) to install the GRUB core image on.



dd if=/dev/sda1 of=/dev/sdb1
efibootmgr -c -d /dev/sdb -p 1 -w -L 'debian backup' -l

'\EFI\debian\grubx64.efi'

And now "efibootmgr -v" shows:


Boot000E* debian backup

HD(1,GPT,96aa190b-b6c0-4753-ab6f-171ccc37b745,0x800,0x79800)/File(\EFI\debian\grubx64.efi)


Boot000F* debian

HD(1,GPT,3ec825d3-e2f7-4491-b4a5-321032b0ab8c,0x800,0x79800)/File(\EFI\debian\grubx64.efi)


Beware that using dd clones the partition, including the UUID and label. 
So both the original and cloned partition have the same UUID, which will 
confuse libblkid and result in either being mounted on /boot/efi.



I guess that will work, though I haven't rebooted yet. What I find weird
is that grub in legacy mode will install to all hard drives in the
system, or at least it would prompt you for what hard drives you wanted
it to be installed to. Why can't grub with efi just automatically do
that same?


Because grub-install works quite differently on EFI targets. It does not 
install on a device but on an EFI system partition mount point. Also, it 
requires to specify explicit IDs for multiple copies. Also, whhen using 
the default ID ("debian"), it deletes any existing EFI boot entry whose 
name contains "debian" (case insensitive IIRC).




ANN: lynx2.8.9dev.14

2017-05-10 Thread Karen Lewellen

Sharing as there are debian references.
Karen


On Thu, 11 May 2017, Thomas Dickey wrote:
 Files:
ftp://invisible-island.net/lynx/patches/lynx2.8.9dev.14.patch.gz
ftp://invisible-island.net/lynx/patches/lynx2.8.9dev.14.patch.gz.asc
ftp://invisible-island.net/lynx/tarballs/lynx2.8.9dev.14.tar.bz2
ftp://invisible-island.net/lynx/tarballs/lynx2.8.9dev.14.tar.bz2.asc
ftp://invisible-island.net/lynx/tarballs/lynx2.8.9dev.14.tar.gz

ftp://invisible-island.net/lynx/tarballs/lynx2.8.9dev.14.tar.gz.asc

ftp://invisible-island.net/lynx/tarballs/lynx2.8.9dev.14.zip

 2017-05-10 (2.8.9dev.14)
 * amend fix for Debian #841155, adding check for complete multibyte strings to
  decide when the cell-limit has been met (Debian #862148) -TD
 * minor improvements to configure script to reduce warnings in config.log -TD
 * update config.sub (2017-04-02)
 * compiler-warning fixes for c99 on OSX -TD




Re: Encrypted RAID1 for storage with Debian Jessie

2017-05-10 Thread commentsabout

Hello,

On 2017-04-19 09:11, tv.deb...@googlemail.com wrote:

System on usb flash disks always caused me troubles, I use it only if
the system can be loaded in ram at boot time and the drive isn't used
for write operation. A low-end small SSD would be a far better option
in my opinion.


Thanks for the advice. I managed to find a 40 Go Intel SSD, for under 
30€ :)


On 2017-04-19 15:06, Joshua Schaeffer wrote:

I can't speak to your system being on USB, but in general you can just
do something like the following:

$mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sda
/dev/sdb
$mdadm --create /dev/md1 --level=1 --raid-devices=2 /dev/sdc
/dev/sdd
$mdadm --create /dev/md2 --level=1 --raid-devices=2 /dev/sde
/dev/sdf

If you want to use LVM then you create the PV, VG, and LV:

$pvcreate /dev/md0
$pvcreate /dev/md1
$pvcreate /dev/md2
$vgcreate vg_data1 /dev/md0
$vgcreate vg_data2 /dev/md1
$vgcreate vg_data3 /dev/md2
$lvcreate vg_data1 -n lv_data1 -L 
$lvcreate vg_data2 -n lv_data2 -L 

$lvcreate vg_data3 -n lv_data3 -L 

Then create your LUKS partition:

$cryptsetup -v --verify-passphrase luksFormat /dev/mapper/lv_data1
vg_data1-lv_data1_crypt
$cryptsetup -v --verify-passphrase luksFormat /dev/mapper/lv_data2
vg_data2-lv_data2_crypt

$cryptsetup -v --verify-passphrase luksFormat /dev/mapper/lv_data3
vg_data3-lv_data3_crypt

Then create your filesystem and mount them:

$mkfs.ext4 /dev/mapper/vg_data1-lv_data1_crypt
$mkfs.ext4 /dev/mapper/vg_data2-lv_data2_crypt

$mkfs.ext4 /dev/mapper/vg_data3-lv_data3_crypt

$mount -t ext4 /dev/mapper/vg_data1-lv_data1_crypt /mnt/data1
$mount -t ext4 /dev/mapper/vg_data2-lv_data2_crypt /mnt/data2

$mount -t ext4 /dev/mapper/vg_data3-lv_data3_crypt /mnt/data3


Thank you for the detailed explanations.

I'm a complete noob when it comes to this kind of operations, so, sorry 
for the dumb question : following tv.debian@'s advises, I purchased a 
cheap SSD and installed my system on it (the SSD, and one pair of HDD 
are plugged in). From there on, how should I proceed ?


Thanks in advanced for your help.

CA



Re: UEFI + Raid

2017-05-10 Thread Sam Smith

On 05/09/2017 05:44 PM, Pascal Hambourg wrote:

Le 09/05/2017 à 01:48, Sam Smith a écrit :


I have installed Debian Stretch on my first system using UEFI. I used a
two disk Raid 1 + LVM configured during install time to mount / on
(among other things).

But now I need to figure out how to add redundancy to the software raid
1 since I believe boot entries are only added to one disk during
installation time?


I did it with Wheezy and wrote a post about it in a french forum. But it
isn't very useful if you cannot read french, and it does not take into
account new fancy grub-install options available since Jessie :
--removable
--force-extra-removable
--efi-directory
--bootloader-id


According to
https://wiki.debian.org/UEFI#Missing_features there doesn't seem to be
much options. Is my only option to copy the FAT32 EFI system partition
from the first disk to the second disk and then use efibootmgr to add it
(the second disk) as a boot entry?


No, you have other options.
Manually install a copy of the GRUB EFI core image in the EFI removable
path of each disk. This location does not require to add an EFI boot
entry with efibootmgr.
Or use grub-install with --removable and --efi-directory for each disk.
Or use grub-install with --efi-directory and --bootloader to install a
copy of GRUB wherever you want and add an EFI boot entry for it.

Maybe you could also create a RAID 1 array with superblock at the end
and use it as the EFI system partition. Never tried it.


And will any subsequent kernel or
grub updates affect the system partition and thus require another
copy/sync to the second disk?


Kernel update : no, it just affects the /boot contents.
GRUB package update : yes.







Thanks for the tips.

I tried to use "grub-install -v  --target=x86_64-efi 
--bootloader-id=grub /dev/sdb"


But as far as I could tell everything was installed to the first disk 
still (sda) and /boot/efi/EFI/ then had two entries, the old 'debian' 
one and then new 'grub' one.



"efibootmgr -v" showed:

> Boot000E* grub 
HD(1,GPT,3ec825d3-e2f7-4491-b4a5-321032b0ab8c,0x800,0x79800)/File(\EFI\grub\grubx64.efi)
> Boot000F* debian 
HD(1,GPT,3ec825d3-e2f7-4491-b4a5-321032b0ab8c,0x800,0x79800)/File(\EFI\debian\grubx64.efi)



Basically on the same disk. I used "efibootmgr -b E -B" to delete the 
extra entry I had just made.


Next I just manually did

> dd if=/dev/sda1 of=/dev/sdb1
> efibootmgr -c -d /dev/sdb -p 1 -w -L 'debian backup' -l 
'\EFI\debian\grubx64.efi'


And now "efibootmgr -v" shows:

> Boot000E* debian backup 
HD(1,GPT,96aa190b-b6c0-4753-ab6f-171ccc37b745,0x800,0x79800)/File(\EFI\debian\grubx64.efi)
> Boot000F* debian 
HD(1,GPT,3ec825d3-e2f7-4491-b4a5-321032b0ab8c,0x800,0x79800)/File(\EFI\debian\grubx64.efi)



I guess that will work, though I haven't rebooted yet. What I find weird 
is that grub in legacy mode will install to all hard drives in the 
system, or at least it would prompt you for what hard drives you wanted 
it to be installed to. Why can't grub with efi just automatically do 
that same?



Regards,
Samuel Smith



Re: How stable is the frozen stretch?

2017-05-10 Thread Fungi4All
From: rave...@sitesplace.net

>My system is used for work (I work from home exclusively) and stuff I do
>sometimes can be mission-critical in that if I'm notified, I might have
>to go and do some work right away on something important. Customers
>would be relying on my ability to fix things. So, I really can't afford
>something to go down on my machine. This is why I have a spare laptop
>just in case my "main" laptop has a problem. They are both set up
>identical and data files are backed up very frequently so all I need to
>do is get the backups onto the spare laptop and be good to go within
>minutes.
>
>Stability, in my case, is a must. However, I do like to have newer
>features as well.

I'd say based on what you describe you should keep your old system and just 
create a small partition to practice debian on your spare time.

By the way, did you guys hear about the mother of all security bugs that was 
uncovered last weekend that affects all ms-win 7,8,10 by some google 
project-group who have yet to uncover a ton of security bugs on android? MS 
already patched it for all the valid licensed customers, which leaves a few 
million out on their crack-jobs.

Re: Strange clicking noise from my laptop hard drive

2017-05-10 Thread Sven Hartge
Bob Weber  wrote:

> To attempt a repair I would boot the  SystemRescueCd and run the
> command 'badblocks  -svn /dev/sdx'.  That is a non destructive read
> then write test and would try to read the bad blocks and if successful
> then write them back giving the drive a chance to relocate the bad
> sector(s).  If this fails and you want to try to fix the drive then
> try spinrite (from grc.com).  It is a commercial program but it does a
> deep scrubbing on the disk and has been able to restore bad disks. 

Before doing _any_ of that, I'd suggest to first do a full backup
creating an image file of the HDD using "dd".

While 'badblocks -svn /dev/sdx' or spinrite may revive the disk, it can
also push the disk "over the edge", damaging it fatally.

Grüße,
Sven.

-- 
Sigmentation fault. Core dumped.



Re: Strange clicking noise from my laptop hard drive

2017-05-10 Thread Bob Weber
On 5/10/17 3:32 PM, Philip Ashmore wrote:
> Hi there.
>
> I managed to record it using my laptops built-in microphone.
>
> To those who would prefer a description:
> It starts fast and slows down. I opened the file with Audacity and determined
> the intervals to be 0.1, 0.3, 0.6, 10, 15 seconds, then it repeats.
>
> It sounds like some kind of protocol negotiation algorithm that requires a
> disk sync when the polling time doubles.
>
Its most likely the disk trying to read some bad sectors.  It is trying to
access the bad sector by approaching it from different ends of the disk ...
that's where the whine sound comes from at different intervals.   This is a bad
sign so get any important data off the drive NOW.

If the system lets you ... run 'smartctl -a /dev/sdx' (replace sdx with your
drive) (if command not found error then install package smartmontools) and look
for things like UDMA_CRC_Error_Count, Offline_Uncorrectable and
Reallocated_Sector_Ct that are high (might just be over zero).  There may be
other messages that indicate drive errors.  You could do a long self test
('smartctl -t long /dev/sdx') but that will only tell you where the errors are. 
If you can get a copy of SystemRescueCd at http://www.system-rescue-cd.org/.  It
is a live Linux repair disk that can do many things.  It has utilities that can
retrieve files from a bad disk and more.  This would give you a chance to mount
the drive and get the important data you need. 

To attempt a repair I would boot the  SystemRescueCd and run the command
'badblocks  -svn /dev/sdx'.  That is a non destructive read then write test and
would try to read the bad blocks and if successful then write them back giving
the drive a chance to relocate the bad sector(s).  If this fails and you want to
try to fix the drive then try spinrite (from grc.com).  It is a commercial
program but it does a deep scrubbing on the disk and has been able to restore
bad disks. 


...bob



Re: Strange clicking noise from my laptop hard drive

2017-05-10 Thread Jhoanir Torres
I think your disk is broken.



On Wed, May 10, 2017 at 2:32 PM, Philip Ashmore 
wrote:

> Hi there.
>
> I managed to record it using my laptops built-in microphone.
>
> To those who would prefer a description:
> It starts fast and slows down. I opened the file with Audacity and
> determined the intervals to be 0.1, 0.3, 0.6, 10, 15 seconds, then it
> repeats.
>
> It sounds like some kind of protocol negotiation algorithm that requires a
> disk sync when the polling time doubles.
>
> Here's a link for your listening pleasure:
> https://www.dropbox.com/s/apdr1o056tam5ie/click.wav?dl=0
>
> I'm hoping it's some cron job, or DropBox, Trinity Desktop, wifi, smart
> disk status monitoring, nVidia, Intel, ... not a virus trying to phone home.
>
> I'm really hoping that someone reading this will go "oh that thing" and
> know what it is instantly.
>
> Curiously it doesn't happen every day.
>
> Regards,
> Philip Ashmore
>
>


-- 
Jhoanir Torres


Strange clicking noise from my laptop hard drive

2017-05-10 Thread Philip Ashmore

Hi there.

I managed to record it using my laptops built-in microphone.

To those who would prefer a description:
It starts fast and slows down. I opened the file with Audacity and 
determined the intervals to be 0.1, 0.3, 0.6, 10, 15 seconds, then it 
repeats.


It sounds like some kind of protocol negotiation algorithm that requires 
a disk sync when the polling time doubles.


Here's a link for your listening pleasure:
https://www.dropbox.com/s/apdr1o056tam5ie/click.wav?dl=0

I'm hoping it's some cron job, or DropBox, Trinity Desktop, wifi, smart 
disk status monitoring, nVidia, Intel, ... not a virus trying to phone home.


I'm really hoping that someone reading this will go "oh that thing" and 
know what it is instantly.


Curiously it doesn't happen every day.

Regards,
Philip Ashmore



Re: bleeding-edge MATE

2017-05-10 Thread songbird
David Griffith wrote:
>
> I've installed MATE 1.18 into /usr/local/ and added 
> /usr/local/share/xsessions to the sessions-director path in 
> /etc/lightdm/lightdm.conf.  At the Lightdm login screen, I can now select 
> MATE for my desktop environment, but on logging in, MATE won't start. 
> What's wrong?  I don't see anything relevant in /var/log about this.

  i've not done this.  sorry can't be of more direct help
but you give me no idea where you are coming from on this
or the amount of experience you have with trying it.


> I can start mate-session in .xinitrc and use startx, but then MATE can't 
> find any themes... and I really would rather use Lightdm.
>
> Is anyone here tinkering with bleeding-edge MATE?  How are you going about 
> it?

  i wasn't sure if you were referring to a specific
project by that name or just the idea of getting the 
most recent MATE tars and building your own.

  after looking i don't see any project by that name
so...

  have you looked at the MATE project pages for building
and installing?

http://mate-desktop.org/

  the community page seems appropriate:

and i wandered through:

http://wiki.mate-desktop.org/building
http://wiki.mate-desktop.org/download
http://wiki.mate-desktop.org/buildscript

  i'm not quite ready to attempt it, short on time
today.

  also there is the pkg-mate-team archives at:

http://lists.alioth.debian.org/pipermail/pkg-mate-team/

  but i'd use that as a last resort since they are
busy enough with packaging/bugs/etc (getting ready
for stretch).

  the other more obvious things to do would be
to get the packages as made already and see where
and how they are putting things.

$ apt-get build-dep pkg

  then

$  apt-get source pkg

  and see how it is put together and what patches
are being applied when set up and building...


  songbird



Re: Using 2nd monitor with Stretch and MATE desktop

2017-05-10 Thread Richard Owlett

On 05/10/2017 01:15 AM, Johann Spies wrote:


arandr is a graphical frontend to xrandr.



Having started to read the man page for xrandr I launched arandr. A few 
minutes of experimentation got me a quite usable interim solution to an 
immediate problem - legibly displaying mariadb documentation.





Re: How stable is the frozen stretch?

2017-05-10 Thread Michael Milliman
On 05/10/2017 06:57 AM, songbird wrote:
[...]
>   if you wanted to you could have one partition for
> booting the stable distribution and only update that
> when you have a good time for that.
> 
>   the thing with these setups is that in Debian you
> don't have to get automatic updates if you don't want
> them so you know when the system is being upgraded.
> 
IMHO, this is a most excellent way of doing things, given that time is
available to maintain such a system.  This way, you have the best of all
worlds. And can incorporate newer packages and versions as they are
available and tested on your system into your working system.


> 
>   songbird
> 

-- 
73's,
WB5VQX -- The Very Quick X-ray



Re: Using 2nd monitor with Stretch and MATE desktop

2017-05-10 Thread Richard Owlett

On 05/09/2017 11:49 AM, Julian Rüger wrote:


On a closer look, kmag seems much more intuitive than xzoom.

The other instructions still work, just replace xzoom with kmag.

In step 9, click the "Mouse" button in kmag's toolbar, to make it follow
your mouse cursor.

Does that work for you?


I didn't find xzoom what I was looking for.
kmag crashed on my system.
I gave fairly detailed error messages and recovery suggestions.
I decided to experiment with other suggestions in this thread.
Thanks.






Re: an fstab question

2017-05-10 Thread Martin McCormick
Ben Caradoc-Davies  writes:
> Martin, please show us the failing line. noatime works fine for me in 
> fstab

Thank you. Your example reminded me of the error of my
ways or rather syntax.

The , was missing in the following line:

UUID=[] /   noatime,errors=remount-ro   
0   1
and now everything seems to be quite normal. I tested it by 

mount -a

so now I will try a reboot and hope I don't need the rescue disk.

Again, many thanks.



Re: How stable is the frozen stretch?

2017-05-10 Thread songbird
RavenLX wrote:
> My system is used for work (I work from home exclusively) and stuff I do 
> sometimes can be mission-critical in that if I'm notified, I might have 
> to go and do some work right away on something important. Customers 
> would be relying on my ability to fix things. So, I really can't afford 
> something to go down on my machine. This is why I have a spare laptop 
> just in case my "main" laptop has a problem. They are both set up 
> identical and data files are backed up very frequently so all I need to 
> do is get the backups onto the spare laptop and be good to go within 
> minutes.
>
> Stability, in my case, is a must. However, I do like to have newer 
> features as well.

  you can set up several partitions with different
levels of fun if you want.

  i run testing and some packages from unstable or
experimental at times as two different booting systems.
to make sure that i always have a bootable system i 
only update the partitions in steps several months 
apart which means i have at least one of them that 
boots and is pretty well tested for the programs i
use the most often.

  if you wanted to you could have one partition for
booting the stable distribution and only update that
when you have a good time for that.

  the thing with these setups is that in Debian you
don't have to get automatic updates if you don't want
them so you know when the system is being upgraded.


  songbird



Re: Segmentation fault in top -b1 -hc

2017-05-10 Thread Curt
On 2017-05-09, Bob McGowan  wrote:
>>
> I just tried the OP's command line and got the following error:
>
> $ top -b1 -hc
>   procps-ng 3.3.12
> Usage:
>   top -hv | -bcHiOSs -d secs -n max -u|U user -p pid(s) -o field -w [cols]
>
> I can say with assurance that I have not manually installed anything
> related to procps or top.
>
> And the policy for procps says:
>
> $ apt-cache policy procps  
> procps:
>   Installed: 2:3.3.12-3
>   Candidate: 2:3.3.12-3
>   Version table:
>
> Those version numbers match the numeric part of the 'top' output.
>
> Could it be that Debian has just dropped the '-ng' from the name?
>

I'm reading that in 2011 Debian, Fedora and openSUSE forked procps (which became
'procps-ng'-- next generation). I guess the package has gone back to being
called procps (or something)?

https://gitlab.com/procps-ng/procps/wikis/faq



-- 
"It might be a vision--of a shell, of a wheelbarrow, of a fairy kingdom on the
far side of the hedge; or it might be the glory of speed; no one knew." --Mrs.
Ramsay, speculating on why her little daughter might be dashing about, in "To
the Lighthouse," by Virginia Woolf.



Re: Using 2nd monitor with Stretch and MATE desktop

2017-05-10 Thread Felix Miata
Johann Spies composed on 2017-05-10 08:15 (UTC+0200):

> Felix Miata wrote:

>> After an xrandr man page refresh, using the following in a startup script:
...
>> xrandr --fb 1920x1200
>> xrandr --dpi 120 --output DVI-I-1 --mode 1920x1200
>> xrandr --output VGA-1 --pos 0x0 --mode 640x480 --panning \
>> 1920x1200+0+0/1920x1200+0+0/64/64/64/64
...
> arandr is a graphical frontend to xrandr.

IIUC:

Adding arandr-0.1.9 here installed 10 packages (24MB) (on Stretch) and NAICT
works on a per user per DE/WM basis. Using xrandr "directly" (via text editor
and script) means both that discrete tweaks with a text editor are not obscured
in (one or more)(hidden) location(s) (deep?) in $HOME, and can be applied
globally, rather than needed by *each* user for *each* DE. Its man page is quite
terse, describing only two options not counting showversion and help.

All correct?
-- 
"The wise are known for their understanding, and pleasant
words are persuasive." Proverbs 16:21 (New Living Translation)

 Team OS/2 ** Reg. Linux User #211409 ** a11y rocks!

Felix Miata  ***  http://fm.no-ip.com/