Welcome! Log In Create A New Profile

Advanced

OXNAS - Command line to determine if PCI or Not?

Posted by grayman4hire 
OXNAS - Command line to determine if PCI or Not?
April 06, 2015 12:09PM
I'm going to put together a tutorial on setting up Debian on the Pogoplug v3/Pro leveraging @bodhi's work.

What's a easy way via command line (from the stock Pogoplug OS) to determine if the Pogoplug is a Pro vs Classic? Basically to help determine which appropriate DTB file (ox820-pogoplug-pro.dtb or ox820-pogoplug-classic.dtb) to use.

Thanks
Re: OXNAS - Command line to determine if PCI or Not?
April 06, 2015 03:29PM
grayman4hire,

> I'm going to put together a tutorial on setting up
> Debian on the Pogoplug v3/Pro leveraging @bodhi's
> work.

Thanks gray.

> What's a easy way via command line (from the stock
> Pogoplug OS) to determine if the Pogoplug is a Pro
> vs Classic? Basically to help determine which
> appropriate DTB file (ox820-pogoplug-pro.dtb or
> ox820-pogoplug-classic.dtb) to use.

There are a few ways. Easiest is the command lspci, which I believe should be there. If you see nothing coming back, its a Pogo Classic. If a Pogo Pro, then PCI is populated.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: OXNAS - Command line to determine if PCI or Not?
April 06, 2015 04:13PM
I'm pretty sure there is no "lspci" command available in the stock Pogoplug OS. I can't verify because my Pro is already running Debian.

Maybe a "dmesg | grep pcie" is sufficient. I believe I have a unmodified P21 (OXNAS) somewhere to test on.
Re: OXNAS - Command line to determine if PCI or Not?
April 06, 2015 04:31PM
grayman4hire Wrote:
-------------------------------------------------------
> I'm pretty sure there is no "lspci" command
> available in the stock Pogoplug OS. I can't verify
> because my Pro is already running Debian.
>
> Maybe a "dmesg | grep pcie" is sufficient. I
> believe I have a unmodified P21 (OXNAS) somewhere
> to test on.

The problem with using dmesg is that the PCI driver should show up, since the same kernel is used for both versions. I guess you would have to look back to stock dmesg in both boxes to know for sure.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: OXNAS - Command line to determine if PCI or Not?
April 08, 2015 02:16AM
I kept it simple and defaulted to the pogoplug classic dtb since it works for both the PCI and non-PCI version. Enabling Wi-Fi/PCI can be done separately.
Re: OXNAS - Command line to determine if PCI or Not?
April 08, 2015 05:07AM
grayman4hire,

> I kept it simple and defaulted to the pogoplug
> classic dtb

I think that's a kludgy approach! you should be able to determine which box. If not possible, then ask the user to figure out which box they have by looking at the model number (not rocket science!).

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: OXNAS - Command line to determine if PCI or Not?
April 08, 2015 05:43AM
if you ran the dmesg output and looked for module load failure, wouldnt that show if the pci loaded and that could be used as proof of the "type"?
Re: OXNAS - Command line to determine if PCI or Not?
April 08, 2015 11:45AM
bodhi Wrote:
-------------------------------------------------------
> grayman4hire,
>
> > I kept it simple and defaulted to the pogoplug
> > classic dtb
>
> I think that's a kludgy approach! you should be
> able to determine which box. If not possible,
> then ask the user to figure out which box they
> have by looking at the model number (not rocket
> science!).

True, it's a little kludgy. However, defaulting to the pogoplug classic dtb guarantees a bootable system regardless of which Oxnas device the user has.

Setting up Wi-Fi requires additional packages and configuration anyways, so if the user has a Pro and wants to use the Wi-Fi, it's one additional command to update the env to point at the pogoplug pro dtb file.

Yes, it's not rocket science, however I think you maybe overestimating people on the internet. I've had at least two users brick their Pogoplug because they followed my PPv4 tutorial and installed the PPv4 uBoot on their E02 and Oxnas device. Why would they do that even though the tutorial clearly states its for the PPv4? Translation issue? Lack of reading comprehension? Pure stupidity? I don't know. :)
Re: OXNAS - Command line to determine if PCI or Not?
April 08, 2015 11:49AM
Gravelrash Wrote:
-------------------------------------------------------
> if you ran the dmesg output and looked for module
> load failure, wouldnt that show if the pci loaded
> and that could be used as proof of the "type"?

I found a good way to detect it, but it requires me writing a script which I don't want to do at this point.

For the record, it documented in the archlinuxarm oxnas installation script - http://os.archlinuxarm.org/os/oxnas/oxnas-install.sh
Re: OXNAS - Command line to determine if PCI or Not?
April 08, 2015 03:18PM
grayman4hire,

> Yes, it's not rocket science, however I think you
> maybe overestimating people on the internet. I've
> had at least two users brick their Pogoplug
> because they followed my PPv4 tutorial and
> installed the PPv4 uBoot on their E02 and Oxnas
> device. Why would they do that even though the
> tutorial clearly states its for the PPv4?
> Translation issue? Lack of reading comprehension?
> Pure stupidity? I don't know. :)

No. Carelessness and excessive risk taking, and so bricking is a ritual :)

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: