From owner-freebsd-hackers@FreeBSD.ORG Thu Feb 17 10:17:43 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 79F221065672 for ; Thu, 17 Feb 2011 10:17:43 +0000 (UTC) (envelope-from mats.w.lindberg@gmail.com) Received: from mail-iy0-f182.google.com (mail-iy0-f182.google.com [209.85.210.182]) by mx1.freebsd.org (Postfix) with ESMTP id 3EFA48FC16 for ; Thu, 17 Feb 2011 10:17:42 +0000 (UTC) Received: by iyb26 with SMTP id 26so2248982iyb.13 for ; Thu, 17 Feb 2011 02:17:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=y/BxvsTz5PkafYtMEQso2REyZalNbs12OUNolUtGFD8=; b=pJBjIcwv0GvWSPFAJOnzRld6+7P4Vd11svIvCU8dGVDDJVx4+c3Sp2M6wC5WKlqW/w SiW5g3JZRECgO2AtRpGXxLkHumLROw5rrgjtHCmWBiQpmOSure3VtEFsXoy+q22MhoE3 T0pNsFrs5O4sZC7gzmdUyPo9+TqvJiKWnQYuA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=D4C0LC2/6Pwp8iRfsnMns1gpH1VoBczkqB5rPYtWLLAQmElHeaIOpF7G4JMCj1xUD1 tK4lsB1Nel5i5F6tkkM8JJ22AMVkVivJoQRPpNlbDRmFR81KB3QyJ/DENe4u9OXhYP7t rzJ44O0/R7VJjLMiUZyMTyez5avVDGLBCo/N0= MIME-Version: 1.0 Received: by 10.231.31.13 with SMTP id w13mr1373109ibc.143.1297936206991; Thu, 17 Feb 2011 01:50:06 -0800 (PST) Received: by 10.231.13.73 with HTTP; Thu, 17 Feb 2011 01:50:06 -0800 (PST) Date: Thu, 17 Feb 2011 10:50:06 +0100 Message-ID: From: Mats Lindberg To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: sched_setscheduler() behaviour changed?? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Feb 2011 10:17:43 -0000 All, I have been using a small program /rt) that utilize the sched_setscheduler() syscall to set the scheduling policy of a process to SCHED_RR. Been running it FBSD 5.x and 6.x. Now when migrating to FBSD 8.1 I get EPERM back at me. used to be able to run it like e.g. > ./rt -sr -p2 -- prog which started in SCHED_RR policy with priority 2. now in FBSD 8.1 I get EPERM But If I do > rtprio 10 ./rt -sr -p2 -- prog it I dont get EPERM. I'm always root when doing this. My problem is that I have customers that need to run their old 5.x 6.x applications 'as is' in 8.1 whithout changing anything. Does anyone know if there is a workaround? sysctl? kernel hint? kernel config? reverting to 4BSD scheduler? regards Mats