OT - Old PC - Free Operating System Ideas

Jan 02, 2016 211 Replies
Saved reading

Hang on, not only can you not do this with a mouse, as its claimed everything can be done in windows, its not even possible with a text editor, which is what people cant apparently use in Linux (although they can in windows, to edit their HOSTS file, apparently) - no, this requires you WRITE SOME CODE!!

sheesh, Is windows still in the 20th century???

;-)

er yes, I do know that...;-) Sometimes it doesn't work if the code gets stuck deep in the kernel.

One of the better ways is to have a NFS mounted file system and disconnect the network and then try and access the drive that is no longer there.

It does time out after a few tens if minutes.

Oh gas woddles nym shifted again?

Chris,

Thanks, yes, I looked into that one before. Indeed it just returns a nice string that looks OK, trouble is it is not a string that can be found in the tz database - see:

Any of those strings plus a number of others are supported by PHP:

There's a few possible approaches here:

formatting link

But it looks like reading the registry

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation

is what you need to do and the way to do that on windows with php is maybe here.

formatting link
?

But the real answer is, if you want to write php server code, don't start with windows .

En el artículo , The Natural Philosopher escribió:

It's wonderful if you're mounting between Linux machines, but if you try and add in, e.g. Solaris or Tru64 boxes you come across all kinds of weird problems.

On Linux, you can add "bg, intr" to the mount options so that it doesn't block and wait several minutes to timeout a share that's disappeared, e.g.

mount -v -t nfs server:/share /mountpoint -o rw,bg,intr

Changing the block size to 8k can also make a big difference to performance.

mount -v -t nfs server:/share /mountpoint -o rw,bg,intr,rsize=8192,wsize=8192

In message , Tim Streater writes

Ah, I thought you might have found it and wondered if there was a catch.

I suppose in extremis you could do your own lookup table to convert the windows string to a suitable PHP understandable one?

Well yes, but CIFS? spawn of a bigger devil

Yup. Its not even guaranteed between linux as I discovered - later linuxes against earlier servers was takong several minutes to mount - turned out that it was defaulting to a different protocol ..

Im OK with performance

I tried auto and bg IIRC but that led to other issues

Anyway its no big deal because if the server is down almost nothing on this PC works properly anyway.

That will indeed make a big difference to performance - it will make it much worse.

The default rsize and wsize are way bigger than 8k these days:

$ grep -o '[rw]size[^,]*,' /proc/mounts rsize=1048576, wsize=1048576, rsize=1048576, wsize=1048576, rsize=1048576, wsize=1048576,

En el artículo , Geoff Clare escribió:

It depends on the network. I did a *lot* of testing and found 8k to be the optimum size, because that is the size of the buffers in the network switches we used (Cisco 29xx 100Mbit/s). Any larger and packet fragmentation caused performance to drop.

Also, you may remember I said we were using NFS mounts on Solaris and Tru64 UNIX kit as well, so I had to take those into account. Tru64 locked up hard with an NFS rsize and wsize larger than 8k. Rather inconvenient when it happens to be your main server cluster.

So? Doesn't make it right in all cases. It depends on the specific network, and the optimum size can only be determined by empirical testing on that network.

Those values would also be no good for NFS over the internet.

Does it take windows 10 out in the same way or are you still decades old and why don't you use decades old linux? I know you are old and going senile but you really should try as complaining about decades old software as though its the current stuff is just stupid.

Modify the installer so it asks the TZ and enters it into the php.ini file?

has memory management changed at all in the last 15 years?

It wouldn't affect the program crashing if I did upgrade, anyway. It might not take out windows., that's all, but since restarting windows in a VM is seconds only, it hardly matters.

However the whole thread was about the issues inherent in an OLD XP set up versus a NEW LINUX setup, so you are moving the goal posts

$ grep -o '[rw]size[^,]*,' /proc/mounts rsize=131072, wsize=131072, rsize=131072, wsize=131072, rsize=131072, wsize=131072, rsize=131072, wsize=131072, rsize=131072, wsize=131072, rsize=131072, wsize=131072,

My blocksize is bigger than your blocksize!

Sheesh, PHP is written by the same open source community as linux is, if they can't do something this simple users had better forget about linux until it gets to the 19th century.

That's odd it says its compatible with

Windows 10 (32-bit/64-bit), Windows 8.1 (64-bit), Windows 8 Pro (32-bit/64-bit), Windows 8 Enterprise (32-bit/64-bit), Windows 8 Enterprise N (32-bit/64-bit), Windows 8 Basic (32-bit/64-bit), Windows 7 (including Starter Edition 32-bit and 64-bit), Windows Vista (including Starter Edition 32-bit) Mac OS X 10.7 Lion, OS X 10.8 Mountain Lion, OS X 10.9 Mavericks Mobile Operating Systems: iOS, Android, Windows 8 RT, Windows 10 Mobile Other: Debian (5.0, 5.0.1, 5.0.2, 5.0.3) (supported by the automatic installer), Fedora (9, 9.0, 10, 10.0, 11.0, 11, 12, 12.0), HPUX 11 and Solaris 8/9, Linux (9.4, 9.5), Red Hat Enterprise Linux 5.0 (supported with a pre-built package), SUSE Linux (10.3, 11.0, 11, 11.1, 11.2), Ubuntu (8.04, 8.04.1, 8.04.2, 8.10, 9.04, 9.10, 10.04)

Maybe you just forgot?

Those answers don't work unless you have previously *set* the timezone in your PHP script. Chicken and egg.

Entering that the the c: prompt gives me:

The system cannot find the path specified.

Involves adding an extension to PHP, which I have no idea how to do so can't advise a user how to do it. At this point I don't know, either, what the returned info might look like. If it gives me the same as TZUTIL then I'm no further forward :-)

Well of course. But I'm not writing server code. This is all on the user's machine. They decide what to run it on, not me.

Looks like your .sig delimiter is missing the space.

I could, yes, but it's easier to let the user edit a line in one of the scripts.

It was certainly irritating when this started happening, that is, until you tell PHP what the time zone is, no time/date function will work. Happened around PHP 3.3, IIRC. I dunno why PHP doesn't find out for itself on startup. I also dunno why when you ask Windows what the timezone is, you get a non-standard ambiguous string back.

THats because its not a file, its a key value pair in the registry. Try regedit.

] Its documented on the net

At this point I don't know, either,

have a look with regedit

how come you are using PHP then? Thats server side code.

Use java or javascript for client side

occasionally gets deleted

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required