I need a portable php lib to get cpu and/or HD serial number and other physical addresses if there is any. I know on php it needs exec or shell command but is there a such RELIABLE lib on packagist or github?
Thanks. It was very useful. But on all platforms this is not the same command or the file you should look into get cpu/HD serial numbers. By “portable lib” to do so, I meant that. Is there anything useful?
I doubt there is one. just consider the differences between Linux & Windows.
Just off topic: run() of symfony process is switchable between all available commands? For example if any of passthru, shell, shell_exec, exec is disabled, it will find the one will work automatically?
This is what I wrote to my host. I am root.
I tried to install “yum install dmidecode” to get cpu serial number but when I try to run a command I get “not permitted” error.
- Please fix our dmidecode.
- Let us know how we can get cpu and HD serial number of our vps?
At meanwhile, any idea why dmidecode may return not permitted error as I am root?
No. symfony/process exclusively uses proc_* functions as the others are too restricted.
According to phpinfo
System Linux **** 2.6.32-042stab116.1 #1 SMP Wed May 4 16:21:02 MSK 2016 x86_64
So probably not a wrong OS!
What is the best way to get cpu/HD serial number on *nix series?
Never needed to know that, so I have no idea.
According to this info http://0pointer.de/blog/projects/ids.html is machine-id useful for licensing beside mac or it may be changed on each reboot?
This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.