is it safe to use swap over iSCSI?

239 views
Skip to first unread message

Tomasz Chmielewski

unread,
Feb 9, 2009, 5:11:42 AM2/9/09
to open-...@googlegroups.com
Is it safe to use swap over iSCSI?
Or will the system deadlock under memory pressure?

There were some patches for swapping over NFS lately on lkml, which is
"a bit" similar.


--
Tomasz Chmielewski
http://wpkg.org

Ulrich Windl

unread,
Feb 9, 2009, 5:35:08 AM2/9/09
to open-...@googlegroups.com
On 9 Feb 2009 at 11:11, Tomasz Chmielewski wrote:

>
> Is it safe to use swap over iSCSI?
> Or will the system deadlock under memory pressure?

Why should a system deadlock? You mean iSCSI needs memory (for TCP transport) to
page out, but getting that memory would trigger annother page out?

>
> There were some patches for swapping over NFS lately on lkml, which is
> "a bit" similar.

If the system (and subsystems) reserver some emergency memory buffers, there
should be no such problem, but trying may be better than guessing ;-)

Regards,
Ulrich

Tomasz Chmielewski

unread,
Feb 9, 2009, 5:40:30 AM2/9/09
to open-...@googlegroups.com
Ulrich Windl schrieb:

> On 9 Feb 2009 at 11:11, Tomasz Chmielewski wrote:
>
>> Is it safe to use swap over iSCSI?
>> Or will the system deadlock under memory pressure?
>
> Why should a system deadlock? You mean iSCSI needs memory (for TCP transport) to
> page out, but getting that memory would trigger annother page out?

Yes. See also this discussion:

http://kerneltrap.org/Linux/Swap_Over_NFS


>> There were some patches for swapping over NFS lately on lkml, which is
>> "a bit" similar.
>
> If the system (and subsystems) reserver some emergency memory buffers, there
> should be no such problem, but trying may be better than guessing ;-)

Does something like this exist in Linux kernel? "Emergency memory buffer"?

Mike Christie

unread,
Feb 9, 2009, 12:34:54 PM2/9/09
to open-...@googlegroups.com
Tomasz Chmielewski wrote:
> Is it safe to use swap over iSCSI?
> Or will the system deadlock under memory pressure?
>

Probably deadlock.

> There were some patches for swapping over NFS lately on lkml, which is
> "a bit" similar.
>

The same guy that made the swap over NFS patches had worked on patches
for iscsi too. When the iscsi patches were in the same patchset as the
nfs ones he was ccing the list I thought. I think because he had to
rework patches for usptream comments and because the iscsi code changed
on him which broke the iscsi patches, he was just maintaining the nfs
patches for now.

I have not been keeping up with the nfs patches. Did they go upstream?

Reply all
Reply to author
Forward
0 new messages