Re: dump LOB status

2020-09-29 Thread Juha Erkkilä



> On 26. Sep 2020, at 9.31, Otto Moerbeek  wrote:
> Indeed, that commit was reverted in FreeBSD. This should do better. I
> do not like the assert FreeBSD has, so I turned into an quit().

Works for me.  Thanks!

> Index: tape.c
> ===
> RCS file: /cvs/src/sbin/dump/tape.c,v
> retrieving revision 1.45
> diff -u -p -r1.45 tape.c
> --- tape.c28 Jun 2019 13:32:43 -  1.45
> +++ tape.c26 Sep 2020 06:30:37 -
> @@ -330,7 +330,10 @@ flushtape(void)
>   }
> 
>   blks = 0;
> - if (spcl.c_type != TS_END) {
> + if (spcl.c_type != TS_END && spcl.c_type != TS_CLRI &&
> + spcl.c_type != TS_BITS) {
> + if (spcl.c_count > TP_NINDIR)
> + quit("c_count too large\n");
>   for (i = 0; i < spcl.c_count; i++)
>   if (spcl.c_addr[i] != 0)
>   blks++;



Re: LTE SIM in a ThinkPad T400

2020-09-29 Thread Stuart Henderson
On 2020-09-29, Marcus MERIGHI  wrote:
> h...@stare.cz (Jan Stary), 2020.09.29 (Tue) 10:19 (CEST):
>> This is current/amd64 on a ThinkPad T400 (dmesg below).
>
> I don't see any umsm(4) or umb(4) device in you dmesg.
> (Or anything else that looks like a 2/3/4/5G modem.)
>
> Could it be that the SIM slot is provided on all models, 
> though yours doesn't have the "modem"-hardware?

Yes that is very likely.

> Or do you need to enable it in the BIOS?

Check it isn't just disabled in BIOS, if not you should be able to add a
3G card easily enough (you can find them stripped out of old Thinkpads
on ebay etc), but LTE is likely to be trickier, I don't think T400
originally came with them and the BIOS has a whitelist so as well as the
card you'll probably need to find a hacked BIOS too.

One problem with 3g is that most devices you'll find emulate serial ports
so you have to deal with pppd mess. With LTE quite a few of the cards
are supported by umb(4) which are far less annoying.




Re: Encrypted notepad software suggestions

2020-09-29 Thread bijan

On 9/28/20 11:12 PM, Jacqueline Jolicoeur wrote:

Simply Text File encryption is suitable too to hide some info from plain text 
files I have.


You can encrypt text files simply using tools in the base system.

EXAMPLES

Edit, encrypt, and erase:

$ vi file.txt
$ openssl aes-256-cbc -a -iter 10 -in file.txt -out file.txt.enc
$ rm -P file.txt

Restore, and edit:

$ openssl aes-256-cbc -d -a -iter 10 -in file.txt.enc -out file.txt
$ vi file.txt

SEE ALSO
openssl(1), rm(1)



Hmmm, very interesting idea.

It is also possible to invoke external commands on vi(1) buffer and 
replace the content by it's output.


For example:

$ vi
# Write a few words or so
# To encrypt, run
:%!openssl aes-256-cbc -e -a -iter 10 -pass 'pass:123'
# To decrypt, run
:%!openssl aes-256-cbc -d -a -iter 10 -pass 'pass:123'

although I coundn't find a workaround for entering the password from 
standard input, It should be doable, I guess.




Re: sysupgrade with latest snapshot: The directory '/home/_sysupgrade/' does not exist.

2020-09-29 Thread Peter N. M. Hansteen
[cutting back on tos to just misc@]

On Tue, Sep 29, 2020 at 02:25:15PM +0200, Why 42? The lists account. wrote:
> 
> have in the back of my mind "consider repairing" ...
> 
> So I just have to ask ... what then would be the supported/approved disk
> layout for OpenBSD 6.8 on my Intel 8i5 NUC with the following storage:
> 
> 1. A 2TB Samsung SSD: Currently identified as:
> sd0 at scsibus1 targ 2 lun 0:  
> naa.5002538e4109632a
> sd0: 1953514MB, 512 bytes/sector, 4000797360 sectors, thin
> 
> 2. A 512GB Samsung M.2 NVMe device: Currently identified as:
> sd1 at scsibus2 targ 1 lun 0: 
> sd1: 476940MB, 512 bytes/sector, 976773168 sectors

That's close enough to my 2017-vintage laptop that has been through countless
sysupggrades, which has:

sd0 at scsibus0 targ 0 lun 0:  naa.5002538e4098fefc
sd0: 1907729MB, 512 bytes/sector, 3907029168 sectors, thin
sd1 at scsibus1 targ 1 lun 0: 
sd1: 488386MB, 512 bytes/sector, 1000215216 sectors

which I, based on the suggestions from the installer back then modified
to:

[Tue Sep 29 14:56:15] peter@greyhame:~$ df -h
Filesystem SizeUsed   Avail Capacity  Mounted on
/dev/sd1a 1005M198M757M21%/
/dev/sd0d  1.8T624G1.1T36%/home
/dev/sd1d 31.5G9.5M   29.9G 0%/tmp
/dev/sd1f 98.4G2.8G   90.7G 3%/usr
/dev/sd1g  9.8G268M9.1G 3%/usr/X11R6
/dev/sd1h  108G   17.0G   85.8G17%/usr/local
/dev/sd1k  9.8G2.0K9.3G 0%/usr/obj
/dev/sd1j 49.2G1.2G   45.5G 3%/usr/src
/dev/sd1e 98.4G183M   93.3G 0%/var

No problem ever running sysupgrade on that.

(The install notes can still be found at 
https://bsdly.blogspot.com/2017/07/openbsd-and-modern-laptop.html)

> 
> It's my main desktop system, running XFCE.
> 
> Currently df shows:
> Filesystem SizeUsed   Avail Capacity  Mounted on
> /dev/sd1a 1005M314M640M33%/
> mfs:6361   7.7G331M7.0G 4%/tmp
> /dev/sd1e 58.3G   91.3M   55.3G 0%/var
> /dev/sd1f  2.0G1.2G686M64%/usr
> /dev/sd1g 1005M251M703M26%/usr/X11R6
> /dev/sd1h 19.7G   11.0G7.7G59%/usr/local
> /dev/sd1k  5.9G2.0K5.6G 0%/usr/obj
> /dev/sd1j  2.0G2.0K1.9G 0%/usr/src
> /dev/sd1l  295G   10.0G271G 4%/fast
> /dev/sd0h  1.8T964G758G56%/space

>From this and the earlier discussion I think what confuses sysupgrade is the
lack of /home (did you say you replaced that with a symlink?), which I assume
could be remedied with a bit of renaming of mount points and shuffling things 
around under your new /home. Or starting from scratch, of course.


-- 
Peter N. M. Hansteen, member of the first RFC 1149 implementation team
http://bsdly.blogspot.com/ http://www.bsdly.net/ http://www.nuug.no/
"Remember to set the evil bit on all malicious network traffic"
delilah spamd[29949]: 85.152.224.147: disconnected after 42673 seconds.



Re: sysupgrade with latest snapshot: The directory '/home/_sysupgrade/' does not exist.

2020-09-29 Thread Stuart Henderson
On 2020/09/29 14:25, Why 42? The lists account. wrote:
> 
> On Mon, Sep 28, 2020 at 08:25:34AM -0600, Theo de Raadt wrote:
> > ...
> > So we are at an impasse.  The recommended solution is for people to stop
> > making sysupgrade-incompatible layouts in the future, and to consider
> > repairing their incompatible layouts from the past.
> >
> > if sysupgrade doesn't work, people have the old ways of doing things.
> > doctor doctor it hurts when i layout my disk strangely...
>  
> Hi there,
> 
> So, I think I have a workaround for my issue with sysupgrade and, from my
> side, everything is more or less hunky dory ... but as Theo wrote, now I
> have in the back of my mind "consider repairing" ...
> 
> So I just have to ask ... what then would be the supported/approved disk
> layout for OpenBSD 6.8 on my Intel 8i5 NUC with the following storage:
> 
> 1. A 2TB Samsung SSD: Currently identified as:
> sd0 at scsibus1 targ 2 lun 0:  
> naa.5002538e4109632a
> sd0: 1953514MB, 512 bytes/sector, 4000797360 sectors, thin
> 
> 2. A 512GB Samsung M.2 NVMe device: Currently identified as:
> sd1 at scsibus2 targ 1 lun 0: 
> sd1: 476940MB, 512 bytes/sector, 976773168 sectors
> 
> It's my main desktop system, running XFCE.
> 
> Currently df shows:
> Filesystem SizeUsed   Avail Capacity  Mounted on
> /dev/sd1a 1005M314M640M33%/
> mfs:6361   7.7G331M7.0G 4%/tmp

MFS isn't particularly quick, you might well find one or other of your
SSDs is faster.

> /dev/sd1e 58.3G   91.3M   55.3G 0%/var
> /dev/sd1f  2.0G1.2G686M64%/usr
> /dev/sd1g 1005M251M703M26%/usr/X11R6
> /dev/sd1h 19.7G   11.0G7.7G59%/usr/local
> /dev/sd1k  5.9G2.0K5.6G 0%/usr/obj
> /dev/sd1j  2.0G2.0K1.9G 0%/usr/src
> /dev/sd1l  295G   10.0G271G 4%/fast
> /dev/sd0h  1.8T964G758G56%/space
> 
> (Yeah, yeah, when I installed I made "/var" way too big for some reason.)
> 
> There is a swap area on sd1b of 64GB (twice the size of the RAM). At
> install time I thought about not allocating any swap at all, but I wasn't
> sure if that was a good idea or not.

AIUI it is a bad idea to have no swap. 2xRAM is good if you have a
possible use for kernel crashdumps but that'll take a fair old time on
a 32G system and often doesn't work anyway, I'll usually go for 4-8G or
so.

> That mount "/space" contains essentially all the non OS stuff in
> subdirectories e.g. "home", "images", "videos", "music", "netapp". It
> will eventually be just over 1TB (and then keep growing :). Too big to
> fit on the NVMe stick.

Given what you have shown I would probably just rename /space to /home
(and maybe add a /space -> /home symlink if there is much software
using that path, to avoid tracking it all down to change it).

Example commands

boot> boot -s
...
# fsck -p
# mount -a
# umount /space
# mv space home
# sed -i s,space,home, /etc/fstab
# ln -s home space
# mount /home
# ^D

> The "/fast" mount is used for working/output data from apps e.g.
> Wireshark, Influxdb, Telegraf, Grafana, NetApp.
> 
> How would 6.8 layout these drives differently. if I were to installed it,
> from scratch, for example?

You can see what disklabel auto defaults would be with e.g. "disklabel
-A -n sd0" (-n tells it not to write). I rarely use defaults myself
except by mistake though, they are unsuitable for machines doing
ports development, and often unsuitable for servers, though they
aren't too bad for workstations.


> Output of disklabel below.
> 
> Feel free to ignore this email, since, if I am honest, I am unlikely to
> start moving >1TB of data around for fun (maybe with the next hardware
> refresh). But I would still be interested to hear how it would be done
> differently.
> 
> Cheers,
> Robb.
> 
> 
> disklabel sd0
> # /dev/rsd0c:
> type: SCSI
> disk: SCSI disk
> label: Samsung SSD 860
> duid: 7a1775fef773535e
> flags:
> bytes/sector: 512
> sectors/track: 63
> tracks/cylinder: 255
> sectors/cylinder: 16065
> cylinders: 249038
> total sectors: 4000797360
> boundstart: 64
> boundend: 4000797297
> drivedata: 0
> 16 partitions:
> #size   offset  fstype [fsize bsize   cpg]
>   a:  2097152 1024  4.2BSD   2048 16384 12958
>   c:   40007973600  unused
>   h:   3998699008  2098176  4.2BSD   8192 65536 52270 # /space
> 
> disklabel sd1
> # /dev/rsd1c:
> type: SCSI
> disk: SCSI disk
> label: Samsung SSD 970
> duid: 281ef747da03afe7
> flags:
> bytes/sector: 512
> sectors/track: 63
> tracks/cylinder: 255
> sectors/cylinder: 16065
> cylinders: 60801
> total sectors: 976773168
> boundstart: 1024
> boundend: 976773105
> drivedata: 0
> 16 partitions:
> #size   offset  fstype [fsize bsize   cpg]
>   a:  2097152 1024  4.2BSD   2048 16384 12958 # /
>   b: 67324128  2098176swap# none

X hangs on 3d accel'd desktop (X1C3)

2020-09-29 Thread David Dahlberg
Hi all,

I am not sure, whether this is a problem of a graphics driver (for
bugs@) or whether I messed up my config (ports@). So I am asking here,
where I am definitively off-topic:

Starting with a sysupgrade and pkg_add -u to last weeks -snapshot, GDM
became unresponsive.

Symptoms:
 * I see the plain X server being started (as ususal)
 * GDM takes over (as usual)
   - background/mouse pointer change
   - pointer jumps to lower right
 * Then the screen freezes
   - pointer still moving
 * If I switch back and forth consoles, screen is being redrawn once

This happens with GDM and Gnome, when launched directly; But not with
XFCE or Xenodm/cwm/... It also resebles effects that I have seen, when
Broadwell support was still new, therefore I suspect some issue in the
3D accelleration. But I am pretty much lost when trying to debug X, so
maybe might give me a push into the right direction.

System: Thinkpad X1 Carbon (2015/3rd Gen)
Chipset: Broadwell
xorg.conf: empty

To my lay knowledge, Xorg.log/xdm.log look unsuspicious -> no EE.
(PS: I just noticed the warning about the aperture setting. But I didn't
need it before, don't need it on other machines with modesetting driver,
didn't find any mention about changes on current.html and increasing the
value to 1/2 didn't change anything either - apart from the warning
being removed from the log of course)

Reinstalling base and removing/reinstalling all packages to rule out
corrupt files during update didn't help either.


 dmesg 

OpenBSD 6.8 (GENERIC.MP) #89: Mon Sep 28 06:38:07 MDT 2020
dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP
real mem = 8261632000 (7878MB)
avail mem = 7996207104 (7625MB)
random: good seed from bootblocks
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 2.7 @ 0xacbfd000 (66 entries)
bios0: vendor LENOVO version "N14ET54W (1.32 )" date 03/19/2020
bios0: LENOVO 20BSCTO1WW
acpi0 at bios0: ACPI 5.0
acpi0: sleep states S0 S3 S4 S5
acpi0: tables DSDT FACP ASF! HPET ECDT APIC MCFG SSDT SSDT SSDT SSDT SSDT SSDT 
SSDT SSDT SSDT PCCT SSDT UEFI MSDM BATB FPDT UEFI DMAR
acpi0: wakeup devices LID_(S4) SLPB(S3) IGBE(S4) EXP2(S4) XHCI(S3) EHC1(S3)
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpihpet0 at acpi0: 14318179 Hz
acpiec0 at acpi0
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Intel(R) Core(TM) i5-5200U CPU @ 2.20GHz, 2095.45 MHz, 06-3d-04
cpu0: 
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,SDBG,FMA3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,MOVBE,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,PAGE1GB,RDTSCP,LONG,LAHF,ABM,3DNOWP,PERF,ITSC,FSGSBASE,TSC_ADJUST,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID,RDSEED,ADX,SMAP,PT,SRBDS_CTRL,MD_CLEAR,IBRS,IBPB,STIBP,L1DF,SSBD,SENSOR,ARAT,XSAVEOPT,MELTDOWN
cpu0: 256KB 64b/line 8-way L2 cache
cpu0: smt 0, core 0, package 0
mtrr: Pentium Pro MTRR support, 10 var ranges, 88 fixed ranges
cpu0: apic clock running at 99MHz
cpu0: mwait min=64, max=64, C-substates=0.2.1.2.4.1.1.1, IBE
cpu1 at mainbus0: apid 2 (application processor)
cpu1: Intel(R) Core(TM) i5-5200U CPU @ 2.20GHz, 2095.16 MHz, 06-3d-04
cpu1: 
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,PCLMUL,DTES64,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,SDBG,FMA3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,MOVBE,POPCNT,DEADLINE,AES,XSAVE,AVX,F16C,RDRAND,NXE,PAGE1GB,RDTSCP,LONG,LAHF,ABM,3DNOWP,PERF,ITSC,FSGSBASE,TSC_ADJUST,BMI1,AVX2,SMEP,BMI2,ERMS,INVPCID,RDSEED,ADX,SMAP,PT,SRBDS_CTRL,MD_CLEAR,IBRS,IBPB,STIBP,L1DF,SSBD,SENSOR,ARAT,XSAVEOPT,MELTDOWN
cpu1: 256KB 64b/line 8-way L2 cache
cpu1: smt 0, core 1, package 0
ioapic0 at mainbus0: apid 2 pa 0xfec0, version 20, 40 pins
acpimcfg0 at acpi0
acpimcfg0: addr 0xf800, bus 0-63
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus -1 (PEG_)
acpiprt2 at acpi0: bus 3 (EXP1)
acpiprt3 at acpi0: bus 4 (EXP2)
acpiprt4 at acpi0: bus -1 (EXP3)
acpiprt5 at acpi0: bus 10 (EXP6)
acpibtn0 at acpi0: LID_
acpibtn1 at acpi0: SLPB
acpipci0 at acpi0 PCI0: 0x 0x0011 0x0001
acpicmos0 at acpi0
acpibat0 at acpi0: BAT0 model "00HW002" serial   511 type LiP oem "LGC"
acpiac0 at acpi0: AC unit online
acpithinkpad0 at acpi0: version 1.0
"PNP0C14" at acpi0 not configured
"PNP0C14" at acpi0 not configured
"PNP0C14" at acpi0 not configured
"INT340F" at acpi0 not configured
acpicpu0 at acpi0: C3(200@233 mwait.1@0x40), C2(200@148 mwait.1@0x33), 
C1(1000@1 mwait.1), PSS
acpicpu1 at acpi0: C3(200@233 mwait.1@0x40), C2(200@148 mwait.1@0x33), 
C1(1000@1 mwait.1), PSS
acpipwrres0 at acpi0: PUBS, resource for XHCI, EHC1
acpipwrres1 at acpi0: NVP3, resource for PEG_
acpipwrres2 at acpi0: NVP2, resource for PEG_
acpitz0 at acpi0: critical temperature is 128 degC
acpivideo0 at acpi0: VID_
acpivout0 at acpivideo0: LCD0
acpivideo1 at 

Re: sysupgrade with latest snapshot: The directory '/home/_sysupgrade/' does not exist.

2020-09-29 Thread Why 42? The lists account.


On Mon, Sep 28, 2020 at 08:25:34AM -0600, Theo de Raadt wrote:
> ...
> So we are at an impasse.  The recommended solution is for people to stop
> making sysupgrade-incompatible layouts in the future, and to consider
> repairing their incompatible layouts from the past.
>
> if sysupgrade doesn't work, people have the old ways of doing things.
> doctor doctor it hurts when i layout my disk strangely...
 
Hi there,

So, I think I have a workaround for my issue with sysupgrade and, from my
side, everything is more or less hunky dory ... but as Theo wrote, now I
have in the back of my mind "consider repairing" ...

So I just have to ask ... what then would be the supported/approved disk
layout for OpenBSD 6.8 on my Intel 8i5 NUC with the following storage:

1. A 2TB Samsung SSD: Currently identified as:
sd0 at scsibus1 targ 2 lun 0:  naa.5002538e4109632a
sd0: 1953514MB, 512 bytes/sector, 4000797360 sectors, thin

2. A 512GB Samsung M.2 NVMe device: Currently identified as:
sd1 at scsibus2 targ 1 lun 0: 
sd1: 476940MB, 512 bytes/sector, 976773168 sectors

It's my main desktop system, running XFCE.

Currently df shows:
Filesystem SizeUsed   Avail Capacity  Mounted on
/dev/sd1a 1005M314M640M33%/
mfs:6361   7.7G331M7.0G 4%/tmp
/dev/sd1e 58.3G   91.3M   55.3G 0%/var
/dev/sd1f  2.0G1.2G686M64%/usr
/dev/sd1g 1005M251M703M26%/usr/X11R6
/dev/sd1h 19.7G   11.0G7.7G59%/usr/local
/dev/sd1k  5.9G2.0K5.6G 0%/usr/obj
/dev/sd1j  2.0G2.0K1.9G 0%/usr/src
/dev/sd1l  295G   10.0G271G 4%/fast
/dev/sd0h  1.8T964G758G56%/space

(Yeah, yeah, when I installed I made "/var" way too big for some reason.)

There is a swap area on sd1b of 64GB (twice the size of the RAM). At
install time I thought about not allocating any swap at all, but I wasn't
sure if that was a good idea or not.

That mount "/space" contains essentially all the non OS stuff in
subdirectories e.g. "home", "images", "videos", "music", "netapp". It
will eventually be just over 1TB (and then keep growing :). Too big to
fit on the NVMe stick.

The "/fast" mount is used for working/output data from apps e.g.
Wireshark, Influxdb, Telegraf, Grafana, NetApp.

How would 6.8 layout these drives differently. if I were to installed it,
from scratch, for example?

Output of disklabel below.

Feel free to ignore this email, since, if I am honest, I am unlikely to
start moving >1TB of data around for fun (maybe with the next hardware
refresh). But I would still be interested to hear how it would be done
differently.

Cheers,
Robb.


disklabel sd0
# /dev/rsd0c:
type: SCSI
disk: SCSI disk
label: Samsung SSD 860
duid: 7a1775fef773535e
flags:
bytes/sector: 512
sectors/track: 63
tracks/cylinder: 255
sectors/cylinder: 16065
cylinders: 249038
total sectors: 4000797360
boundstart: 64
boundend: 4000797297
drivedata: 0
16 partitions:
#size   offset  fstype [fsize bsize   cpg]
  a:  2097152 1024  4.2BSD   2048 16384 12958
  c:   40007973600  unused
  h:   3998699008  2098176  4.2BSD   8192 65536 52270 # /space

disklabel sd1
# /dev/rsd1c:
type: SCSI
disk: SCSI disk
label: Samsung SSD 970
duid: 281ef747da03afe7
flags:
bytes/sector: 512
sectors/track: 63
tracks/cylinder: 255
sectors/cylinder: 16065
cylinders: 60801
total sectors: 976773168
boundstart: 1024
boundend: 976773105
drivedata: 0
16 partitions:
#size   offset  fstype [fsize bsize   cpg]
  a:  2097152 1024  4.2BSD   2048 16384 12958 # /
  b: 67324128  2098176swap# none
  c:9767731680  unused
  d:  8388608 69422304  4.2BSD   2048 16384 12958
  e:124326848 77810912  4.2BSD   2048 16384 12958 # /var
  f:  4194304202137760  4.2BSD   2048 16384 12958 # /usr
  g:  2097152206332064  4.2BSD   2048 16384 12958 # /usr/X11R6
  h: 41943040208429216  4.2BSD   2048 16384 12958 # /usr/local
  i:  960   64   MSDOS
  j:  4194304250372256  4.2BSD   2048 16384 12958 # /usr/src
  k: 12582912254566560  4.2BSD   2048 16384 12958 # /usr/obj
  l:629145536267149504  4.2BSD   4096 32768 26062 # /fast



Re: LTE SIM in a ThinkPad T400

2020-09-29 Thread Marcus MERIGHI
h...@stare.cz (Jan Stary), 2020.09.29 (Tue) 10:19 (CEST):
> This is current/amd64 on a ThinkPad T400 (dmesg below).

I don't see any umsm(4) or umb(4) device in you dmesg.
(Or anything else that looks like a 2/3/4/5G modem.)

Could it be that the SIM slot is provided on all models, 
though yours doesn't have the "modem"-hardware?

Or do you need to enable it in the BIOS?

Marcus

> The machine has a slot for a SIM card, and I'm considering
> getting a data-tarif SIM to put in there so it has its own
> connection (although iwn works as a client to a mobile AP).
> 
> Is anyone using a data SIM in a laptop?
> Is that supported at all?
> 
>   Jan
> 
> 
> OpenBSD 6.8-beta (GENERIC.MP) #0: Fri Sep 18 11:00:33 CEST 2020
> h...@lenovo.stare.cz:/usr/src/sys/arch/amd64/compile/GENERIC.MP
> real mem = 8463781888 (8071MB)
> avail mem = 8192241664 (7812MB)
> random: good seed from bootblocks
> mpath0 at root
> scsibus0 at mpath0: 256 targets
> mainbus0 at root
> bios0 at mainbus0: SMBIOS rev. 2.4 @ 0xe0010 (80 entries)
> bios0: vendor LENOVO version "7UET94WW (3.24 )" date 10/17/2012
> bios0: LENOVO 64741EG
> acpi0 at bios0: ACPI 3.0
> acpi0: sleep states S0 S3 S4 S5
> acpi0: tables DSDT FACP SSDT ECDT APIC MCFG HPET SLIC BOOT ASF! SSDT TCPA 
> SSDT SSDT SSDT
> acpi0: wakeup devices LID_(S3) SLPB(S3) IGBE(S4) EXP0(S4) EXP1(S4) EXP2(S4) 
> EXP3(S4) EXP4(S4) PCI1(S4) USB0(S3) USB3(S3) USB5(S3) EHC0(S3) EHC1(S3) 
> HDEF(S4)
> acpitimer0 at acpi0: 3579545 Hz, 24 bits
> acpiec0 at acpi0
> acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
> cpu0 at mainbus0: apid 0 (boot processor)
> cpu0: Intel(R) Core(TM)2 Duo CPU P8400 @ 2.26GHz, 2261.31 MHz, 06-17-06
> cpu0: 
> FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,NXE,LONG,LAHF,PERF,SENSOR,MELTDOWN
> cpu0: 3MB 64b/line 8-way L2 cache
> cpu0: smt 0, core 0, package 0
> mtrr: Pentium Pro MTRR support, 7 var ranges, 88 fixed ranges
> cpu0: apic clock running at 266MHz
> cpu0: mwait min=64, max=64, C-substates=0.2.2.2.2.1.3, IBE
> cpu1 at mainbus0: apid 1 (application processor)
> cpu1: Intel(R) Core(TM)2 Duo CPU P8400 @ 2.26GHz, 2261.01 MHz, 06-17-06
> cpu1: 
> FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,NXE,LONG,LAHF,PERF,SENSOR,MELTDOWN
> cpu1: 3MB 64b/line 8-way L2 cache
> cpu1: smt 0, core 1, package 0
> ioapic0 at mainbus0: apid 1 pa 0xfec0, version 20, 24 pins, remapped
> acpimcfg0 at acpi0
> acpimcfg0: addr 0xe000, bus 0-63
> acpihpet0 at acpi0: 14318179 Hz
> acpiprt0 at acpi0: bus 0 (PCI0)
> acpiprt1 at acpi0: bus -1 (AGP_)
> acpiprt2 at acpi0: bus 2 (EXP0)
> acpiprt3 at acpi0: bus 3 (EXP1)
> acpiprt4 at acpi0: bus -1 (EXP2)
> acpiprt5 at acpi0: bus 5 (EXP3)
> acpiprt6 at acpi0: bus 13 (EXP4)
> acpiprt7 at acpi0: bus 21 (PCI1)
> acpibtn0 at acpi0: LID_
> acpibtn1 at acpi0: SLPB
> acpipci0 at acpi0 PCI0: 0x 0x0011 0x0001
> extent `acpipci0 pcibus' (0x0 - 0xff), flags=0
> extent `pciio' (0x0 - 0x), flags=0
>  0x1 - 0x
> extent `pcimem' (0x0 - 0x), flags=0
>  0x0 - 0xbfff
>  0xe000 - 0xefff
>  0xfec0 - 0xfec0
>  0xfed0 - 0xfed003ff
>  0xfed1 - 0xfed13fff
>  0xfed18000 - 0xfed19fff
>  0xfed1c000 - 0xfed8
>  0xfee0 - 0xfee00fff
>  0xff80 - 0x
>  0x400 - 0x
> acpicmos0 at acpi0
> tpm0 at acpi0 TPM_ addr 0xfed4/0x5000, device 0x10208086 rev 0x6
> acpibat0 at acpi0: BAT0 model "92P1137" serial57 type LION oem "SANYO"
> acpiac0 at acpi0: AC unit online
> acpithinkpad0 at acpi0: version 1.0
> "PNP0C14" at acpi0 not configured
> acpicpu0 at acpi0: !C3(100@57 mwait.3@0x30), !C2(500@1 mwait.1@0x10), 
> C1(1000@1 mwait.1), PSS
> acpicpu1 at acpi0: !C3(100@57 mwait.3@0x30), !C2(500@1 mwait.1@0x10), 
> C1(1000@1 mwait.1), PSS
> acpipwrres0 at acpi0: PUBS, resource for USB0, USB3, USB5, EHC0, EHC1
> acpitz0 at acpi0: critical temperature is 127 degC
> acpitz1 at acpi0: critical temperature is 100 degC
> acpidock0 at acpi0: GDCK not docked (0)
> acpivideo0 at acpi0: VID_
> acpivout0 at acpivideo0: LCD0
> acpivideo1 at acpi0: VID_
> cpu0: Enhanced SpeedStep 2261 MHz: speeds: 2267, 2266, 1600, 800 MHz
> pci0 at mainbus0 bus 0
> pchb0 at pci0 dev 0 function 0 "Intel GM45 Host" rev 0x07
> inteldrm0 at pci0 dev 2 function 0 "Intel GM45 Video" rev 0x07
> drm0 at inteldrm0
> intagp0 at inteldrm0
> agp0 at intagp0: aperture at 0xd000, size 0x1000
> inteldrm0: apic 1 int 16, GM45, gen 4
> "Intel GM45 Video" rev 0x07 at pci0 dev 2 function 1 not configured
> "Intel GM45 HECI" rev 0x07 at pci0 dev 3 function 0 not configured
> puc0 at pci0 dev 3 function 3 "Intel GM45 KT" rev 0x07: ports: 16 com
> com4 at puc0 port 0 apic 1 

Re: LTE SIM in a ThinkPad T400

2020-09-29 Thread Paco Esteban
On Tue, 29 Sep 2020, Jan Stary wrote:

> This is current/amd64 on a ThinkPad T400 (dmesg below).
> The machine has a slot for a SIM card, and I'm considering
> getting a data-tarif SIM to put in there so it has its own
> connection (although iwn works as a client to a mobile AP).
> 
> Is anyone using a data SIM in a laptop?
> Is that supported at all?

Can't say about a T400, but on a T430s it just works.
Put a SIM on it and:

doas ifconfig umb0 apn YOUR_APN up

In my case I had to modify resolv.conf too.

You could take the SIM from your mobile phone and give it a try.

Cheers,

-- 
Paco Esteban.
0x5818130B8A6DBC03



LTE SIM in a ThinkPad T400

2020-09-29 Thread Jan Stary
This is current/amd64 on a ThinkPad T400 (dmesg below).
The machine has a slot for a SIM card, and I'm considering
getting a data-tarif SIM to put in there so it has its own
connection (although iwn works as a client to a mobile AP).

Is anyone using a data SIM in a laptop?
Is that supported at all?

Jan


OpenBSD 6.8-beta (GENERIC.MP) #0: Fri Sep 18 11:00:33 CEST 2020
h...@lenovo.stare.cz:/usr/src/sys/arch/amd64/compile/GENERIC.MP
real mem = 8463781888 (8071MB)
avail mem = 8192241664 (7812MB)
random: good seed from bootblocks
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 2.4 @ 0xe0010 (80 entries)
bios0: vendor LENOVO version "7UET94WW (3.24 )" date 10/17/2012
bios0: LENOVO 64741EG
acpi0 at bios0: ACPI 3.0
acpi0: sleep states S0 S3 S4 S5
acpi0: tables DSDT FACP SSDT ECDT APIC MCFG HPET SLIC BOOT ASF! SSDT TCPA SSDT 
SSDT SSDT
acpi0: wakeup devices LID_(S3) SLPB(S3) IGBE(S4) EXP0(S4) EXP1(S4) EXP2(S4) 
EXP3(S4) EXP4(S4) PCI1(S4) USB0(S3) USB3(S3) USB5(S3) EHC0(S3) EHC1(S3) HDEF(S4)
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpiec0 at acpi0
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Intel(R) Core(TM)2 Duo CPU P8400 @ 2.26GHz, 2261.31 MHz, 06-17-06
cpu0: 
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,NXE,LONG,LAHF,PERF,SENSOR,MELTDOWN
cpu0: 3MB 64b/line 8-way L2 cache
cpu0: smt 0, core 0, package 0
mtrr: Pentium Pro MTRR support, 7 var ranges, 88 fixed ranges
cpu0: apic clock running at 266MHz
cpu0: mwait min=64, max=64, C-substates=0.2.2.2.2.1.3, IBE
cpu1 at mainbus0: apid 1 (application processor)
cpu1: Intel(R) Core(TM)2 Duo CPU P8400 @ 2.26GHz, 2261.01 MHz, 06-17-06
cpu1: 
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,DTES64,MWAIT,DS-CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,NXE,LONG,LAHF,PERF,SENSOR,MELTDOWN
cpu1: 3MB 64b/line 8-way L2 cache
cpu1: smt 0, core 1, package 0
ioapic0 at mainbus0: apid 1 pa 0xfec0, version 20, 24 pins, remapped
acpimcfg0 at acpi0
acpimcfg0: addr 0xe000, bus 0-63
acpihpet0 at acpi0: 14318179 Hz
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus -1 (AGP_)
acpiprt2 at acpi0: bus 2 (EXP0)
acpiprt3 at acpi0: bus 3 (EXP1)
acpiprt4 at acpi0: bus -1 (EXP2)
acpiprt5 at acpi0: bus 5 (EXP3)
acpiprt6 at acpi0: bus 13 (EXP4)
acpiprt7 at acpi0: bus 21 (PCI1)
acpibtn0 at acpi0: LID_
acpibtn1 at acpi0: SLPB
acpipci0 at acpi0 PCI0: 0x 0x0011 0x0001
extent `acpipci0 pcibus' (0x0 - 0xff), flags=0
extent `pciio' (0x0 - 0x), flags=0
 0x1 - 0x
extent `pcimem' (0x0 - 0x), flags=0
 0x0 - 0xbfff
 0xe000 - 0xefff
 0xfec0 - 0xfec0
 0xfed0 - 0xfed003ff
 0xfed1 - 0xfed13fff
 0xfed18000 - 0xfed19fff
 0xfed1c000 - 0xfed8
 0xfee0 - 0xfee00fff
 0xff80 - 0x
 0x400 - 0x
acpicmos0 at acpi0
tpm0 at acpi0 TPM_ addr 0xfed4/0x5000, device 0x10208086 rev 0x6
acpibat0 at acpi0: BAT0 model "92P1137" serial57 type LION oem "SANYO"
acpiac0 at acpi0: AC unit online
acpithinkpad0 at acpi0: version 1.0
"PNP0C14" at acpi0 not configured
acpicpu0 at acpi0: !C3(100@57 mwait.3@0x30), !C2(500@1 mwait.1@0x10), C1(1000@1 
mwait.1), PSS
acpicpu1 at acpi0: !C3(100@57 mwait.3@0x30), !C2(500@1 mwait.1@0x10), C1(1000@1 
mwait.1), PSS
acpipwrres0 at acpi0: PUBS, resource for USB0, USB3, USB5, EHC0, EHC1
acpitz0 at acpi0: critical temperature is 127 degC
acpitz1 at acpi0: critical temperature is 100 degC
acpidock0 at acpi0: GDCK not docked (0)
acpivideo0 at acpi0: VID_
acpivout0 at acpivideo0: LCD0
acpivideo1 at acpi0: VID_
cpu0: Enhanced SpeedStep 2261 MHz: speeds: 2267, 2266, 1600, 800 MHz
pci0 at mainbus0 bus 0
pchb0 at pci0 dev 0 function 0 "Intel GM45 Host" rev 0x07
inteldrm0 at pci0 dev 2 function 0 "Intel GM45 Video" rev 0x07
drm0 at inteldrm0
intagp0 at inteldrm0
agp0 at intagp0: aperture at 0xd000, size 0x1000
inteldrm0: apic 1 int 16, GM45, gen 4
"Intel GM45 Video" rev 0x07 at pci0 dev 2 function 1 not configured
"Intel GM45 HECI" rev 0x07 at pci0 dev 3 function 0 not configured
puc0 at pci0 dev 3 function 3 "Intel GM45 KT" rev 0x07: ports: 16 com
com4 at puc0 port 0 apic 1 int 17: ns16550a, 16 byte fifo
com4: probed fifo depth: 15 bytes
em0 at pci0 dev 25 function 0 "Intel ICH9 IGP M AMT" rev 0x03: msi, address 
00:1c:25:9b:0a:23
uhci0 at pci0 dev 26 function 0 "Intel 82801I USB" rev 0x03: apic 1 int 20
uhci1 at pci0 dev 26 function 1 "Intel 82801I USB" rev 0x03: apic 1 int 21
uhci2 at pci0 dev 26 function 2 "Intel 82801I USB" rev 0x03: apic 1 int 22
ehci0 at pci0 dev 26 function 7 "Intel 82801I USB" rev 0x03: apic 1 int 23
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 configuration 1 interface 0