All of lore.kernel.org
 help / color / mirror / Atom feed
* pdflush -> noflushd related question
@ 2003-05-31 16:41 Michael Buesch
  2003-05-31 17:58 ` Andrew Morton
  0 siblings, 1 reply; 5+ messages in thread
From: Michael Buesch @ 2003-05-31 16:41 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux kernel mailing list

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi.

I want to fix the userspace noflushd daemon to run on 2.5 kernels,
but it seems to get *very* tricky, because bdflush, kupdated have been
replaced by pdflush.

I've grepped through the lkml-archives and I found a post from you, Andrew,
that sayed:

[SNIP]
Subject: [patch] replace kupdate and bdflush with pdflush

- - use a timer to kick off a pdflush thread every five seconds
  to run the kupdate code. 

- - wakeup_bdflush() kicks off a pdflush thread to run the current
  bdflush function.

There's some loss of functionality here - the ability to tune
the writeback periods.  The numbers are hardwired at present.
But the intent is that buffer-based writeback disappears
altogether.  New mechanisms for tuning the writeback will
need to be introduced.
[SNIP]


Yea, but it seems, that I need exactly this lost functionality. :)
noflushd, on 2.4 kernels, prevents the disks to spin up by spinning
them down an stopping the kupdated daemon through putting
the update-interval to 0 via syscall bdflush().
That's the code to do so:
bdflush(2 + (1 << 3) + 1, interval);

So, how to set the interval, or better sayed, how to _stop_
buffer flushing in 2.5?
Has this lost functionality already been re-implemented?
Are there new syscalls?

Thanks for your help.

- -- 
Regards Michael Büsch
http://www.8ung.at/tuxsoft
 18:29:24 up  4:01,  2 users,  load average: 1.11, 1.09, 1.05

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQE+2NtXoxoigfggmSgRArisAJ9KTnvSW51e4OnLvkvjI/D/bUF19ACeK9Yw
xOVOelmYmHd9eC7Unuys8pM=
=t+79
-----END PGP SIGNATURE-----


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: pdflush -> noflushd related question
  2003-05-31 16:41 pdflush -> noflushd related question Michael Buesch
@ 2003-05-31 17:58 ` Andrew Morton
  2003-05-31 18:24   ` Michael Buesch
  2003-05-31 18:36   ` Michael Buesch
  0 siblings, 2 replies; 5+ messages in thread
From: Andrew Morton @ 2003-05-31 17:58 UTC (permalink / raw)
  To: Michael Buesch; +Cc: linux-kernel

Michael Buesch <fsdeveloper@yahoo.de> wrote:
>
>  So, how to set the interval, or better sayed, how to _stop_
>  buffer flushing in 2.5?

/proc/sys/vm has the appropriate tunables.  They are documented in
Documentation/filesystems/proc.txt.

You can turn these guys off by setting the sysctls to 1000000000
I guess.   Problem is, I don't think there's a way of starting them
again until the ten million seconds expires.  hmm.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: pdflush -> noflushd related question
  2003-05-31 17:58 ` Andrew Morton
@ 2003-05-31 18:24   ` Michael Buesch
  2003-05-31 18:36   ` Michael Buesch
  1 sibling, 0 replies; 5+ messages in thread
From: Michael Buesch @ 2003-05-31 18:24 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux kernel mailing list

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Saturday 31 May 2003 19:58, Andrew Morton wrote:
> Michael Buesch <fsdeveloper@yahoo.de> wrote:
> >  So, how to set the interval, or better sayed, how to _stop_
> >  buffer flushing in 2.5?
>
> /proc/sys/vm has the appropriate tunables.  They are documented in
> Documentation/filesystems/proc.txt.
>
> You can turn these guys off by setting the sysctls to 1000000000
> I guess.   Problem is, I don't think there's a way of starting them
> again until the ten million seconds expires.  hmm.

Thanks Andrew, that's a good point to goon hacking. :)
I'll look at it.

- -- 
Regards Michael Büsch
http://www.8ung.at/tuxsoft
 20:21:50 up  5:54,  2 users,  load average: 2.01, 2.02, 2.00

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQE+2PN0oxoigfggmSgRArlBAJ9zZBsnnAjTA8s6cTK7xPeFDM+v+wCffyE/
fLHzyat7wxgEu1902BYQtUg=
=eq9e
-----END PGP SIGNATURE-----


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: pdflush -> noflushd related question
  2003-05-31 17:58 ` Andrew Morton
  2003-05-31 18:24   ` Michael Buesch
@ 2003-05-31 18:36   ` Michael Buesch
  2003-05-31 18:42     ` Andrew Morton
  1 sibling, 1 reply; 5+ messages in thread
From: Michael Buesch @ 2003-05-31 18:36 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux kernel mailing list

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Saturday 31 May 2003 19:58, Andrew Morton wrote:
> You can turn these guys off by setting the sysctls to 1000000000
> I guess.   Problem is, I don't think there's a way of starting them
> again until the ten million seconds expires.  hmm.

I've thought a little bit more about it.
Why do you think, there is no way of waking up?
Is it, because, when I set it to 1000000000 and the back to,
let's say, 500, the pdflush threads don't wake up to recognize
this change? Is this the cause?

What about signaling all pdflush threads with, for example,
for(ALL_PDFLUSHS)
	kill(pid, SIGSTOP);

Don't they wake up then and recognize the reducing of the timeout?
The old noflushd did so to wake up updated.

thanks.

- -- 
Regards Michael Büsch
http://www.8ung.at/tuxsoft
 20:32:32 up  6:04,  2 users,  load average: 2.05, 2.03, 2.00

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQE+2PZHoxoigfggmSgRAjx2AJ9orNNk8SLQlhBg+lJ1ZsyGgOb/9ACgjBjW
bm0WPZwvb8Rd0bGti2XFBOQ=
=Et8g
-----END PGP SIGNATURE-----


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: pdflush -> noflushd related question
  2003-05-31 18:36   ` Michael Buesch
@ 2003-05-31 18:42     ` Andrew Morton
  0 siblings, 0 replies; 5+ messages in thread
From: Andrew Morton @ 2003-05-31 18:42 UTC (permalink / raw)
  To: Michael Buesch; +Cc: linux-kernel

Michael Buesch <fsdeveloper@yahoo.de> wrote:
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> On Saturday 31 May 2003 19:58, Andrew Morton wrote:
> > You can turn these guys off by setting the sysctls to 1000000000
> > I guess.   Problem is, I don't think there's a way of starting them
> > again until the ten million seconds expires.  hmm.
> 
> I've thought a little bit more about it.
> Why do you think, there is no way of waking up?
> Is it, because, when I set it to 1000000000 and the back to,
> let's say, 500, the pdflush threads don't wake up to recognize
> this change? Is this the cause?

Yes.

> What about signaling all pdflush threads with, for example,
> for(ALL_PDFLUSHS)
> 	kill(pid, SIGSTOP);
> 
> Don't they wake up then and recognize the reducing of the timeout?
> The old noflushd did so to wake up updated.

No, that's OK - I'll fix it in the kernel.  It's pretty simple.



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2003-05-31 18:28 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-05-31 16:41 pdflush -> noflushd related question Michael Buesch
2003-05-31 17:58 ` Andrew Morton
2003-05-31 18:24   ` Michael Buesch
2003-05-31 18:36   ` Michael Buesch
2003-05-31 18:42     ` Andrew Morton

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.