Обсуждение: Postgres Process in Kernel Mode?

Поиск
Список
Период
Сортировка

Postgres Process in Kernel Mode?

От
"moises"
Дата:
<div class="Section1"><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB" style="font-size:
10.0pt;font-family:Arial">Hello,</span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial">I’m new in postgres SQL and I have some questions about the space where postgres process
run.</span></font><pclass="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB" style="font-size: 
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial">1-Can any body say me what libs use postgres for make system calls, for example LIBC?
</span></font><pclass="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB" style="font-size: 
10.0pt;font-family:Arial">2-Can any body talk me if some postgres process can run in Linux kernel space?
</span></font><pclass="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB" style="font-size: 
10.0pt;font-family:Arial">3- Some body knows if exist some projects that ports postgres process on Linux kernel
space.</span></font><pclass="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB" style="font-size: 
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial">I was read some source code of postgres, like, </span></font><p class="MsoNormal"><font
face="Arial"size="2"><span lang="EN-GB" style="font-size: 
10.0pt;font-family:Arial">Postgres.C and others…</span></font><p class="MsoNormal"><font face="Arial" size="2"><span
lang="EN-GB"style="font-size: 
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial">I was found C instructions like Printf, that’s prohibitive for Linux kernel applications, for
examplein kernel mode we use printk.</span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial">I suppose that postgres are ported in a user space only. I’m Ok?</span></font><p
class="MsoNormal"><fontface="Arial" size="2"><span lang="EN-GB" style="font-size: 
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial">Thanks </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial">Moises</span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span lang="EN-GB"
style="font-size:
10.0pt;font-family:Arial">- </span></font></div>

Re: Postgres Process in Kernel Mode?

От
Alvaro Herrera
Дата:
moises wrote:

> 1-Can any body say me what libs use postgres for make system calls, for
> example LIBC? 

libc and a lot others.

> 2-Can any body talk me if some postgres process can run in Linux kernel
> space? 

No.

> 3- Some body knows if exist some projects that ports postgres process on
> Linux kernel space.

No that we've heard lately.  (But I remember a guy with a .cu domain
asking not long ago, maybe it was you.)

> I was found C instructions like Printf, that's prohibitive for Linux kernel
> applications, for example in kernel mode we use printk.

That's because Postgres is a user-space program and there are no
intentions to change that.

> I suppose that postgres are ported in a user space only. I'm Ok?

Yes.

If you prefer spanish, I suggest you subscribe to the pgsql-es-ayuda
list.  There is at least one Postgres hacker there.

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.


Re: Postgres Process in Kernel Mode?

От
Chris Browne
Дата:
moises@cedaivc.co.cu ("moises") writes:

> <html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word"
xmlns="http://www.w3.org/TR/REC-html40">
>
> <head>
> <meta http-equiv=Content-Type content="text/html; charset=us-ascii">
> <meta name=Generator content="Microsoft Word 11 (filtered medium)">
> <style>
> <!--
>  /* Style Definitions */
>  p.MsoNormal, li.MsoNormal, div.MsoNormal
>     {margin:0cm;
>     margin-bottom:.0001pt;
>     font-size:12.0pt;
>     font-family:"Times New Roman";}
> a:link, span.MsoHyperlink
>     {color:blue;
>     text-decoration:underline;}
> a:visited, span.MsoHyperlinkFollowed
>     {color:purple;
>     text-decoration:underline;}
> span.EstiloCorreo17
>     {mso-style-type:personal-compose;
>     font-family:Arial;
>     color:windowtext;}
> @page Section1
>     {size:595.3pt 841.9pt;
>     margin:70.85pt 3.0cm 70.85pt 3.0cm;}
> div.Section1
>     {page:Section1;}
> -->
> </style>
>
> </head>
>
> <body lang=ES link=blue vlink=purple>
>
> <div class=Section1>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>Hello,<o:p></o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>I’m new in postgres SQL and I have some
> questions about the space where postgres process run.<o:p></o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>1-Can any body say me what libs use postgres for make
> system calls, for example LIBC? <o:p></o:p></span></font></p>

You can easily determine this yourself using ldd.  The answer will
vary depending on what options you use when compiling it.

> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>2-Can any body talk me if some postgres process can
> run in Linux kernel space? <o:p></o:p></span></font></p>

Yes, it doesn't.

> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>3- Some body knows if exist some projects that ports postgres
> process on Linux kernel space.<o:p></o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>I was read some source code of postgres, like, <o:p></o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>Postgres.C and others…<o:p></o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'> <o:p></o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>I was found C instructions like Printf, that’s prohibitive
> for Linux kernel applications, for example in kernel mode we use printk.<o:p></o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>I suppose that postgres are ported in a user space
> only. I’m Ok?<o:p></o:p></span></font></p>

That's correct.

> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>Thanks <o:p></o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>Moises<o:p></o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
>
> <p class=MsoNormal><font size=2 face=Arial><span lang=EN-GB style='font-size:
> 10.0pt;font-family:Arial'>- <o:p></o:p></span></font></p>
>
> </div>
>
> </body>
>
> </html>

You might want to consider using an email client that doesn't slobber: <p class=MsoNormal><font size=2 face=Arial><span
lang=EN-GBstyle='font-size: 10.0pt;font-family:Arial'><o:p> </o:p></span></font></p>
 
around everywhere.

It's really irritating to have to read around that "deteriorata."
-- 
(format nil "~S@~S" "cbbrowne" "ntlug.org")
http://www3.sympatico.ca/cbbrowne/advocacy.html
A cool feature of OOP is that the simplest examples are 500 lines.  
-- Peter Sestoft


OSCON fallout - Compressed Annealing optimizer

От
Chris Browne
Дата:
Robert Hansen did a talk at OSCON on a compressed annealing framework
called Djinni: <http://sixdemonbag.org/Djinni/>

It's a framework to use compressed annealing (a derivative of
simulated annealing) for finding approximate solutions to NP-complete
problems such as the TSP with time windows.  Note that while Djinni is
implemented in C++, it already supports embedding via SWIG, and has a
C wrapper and is accessible from other languages.  And it's
BSD-licensed...

This has the potential to be an alternative to the present use of GEQO
for query optimization for cases of large joins (e.g. - involving
large numbers of tables).

On the one hand, I'm somewhat suited to looking at this in that I have
the operations research background to know what they're talking about.
On the other hand, I'm not familiar with the optimizer, nor do I deal
with sorts of cases with so many joins that this would be worthwhile.

I've bounced a ToDo entry over to Bruce, and am making sure this is
documented here on pgsql.hackers so that a web search can readily find
it in the future...
-- 
"cbbrowne","@","cbbrowne.com"
http://www3.sympatico.ca/cbbrowne/
"It is far from complete, but it  should explain enough that you don't
just stare at your sendmail.cf file like a deer staring at an oncoming
truck."  -- David Charlap


Re: Postgres Process in Kernel Mode?

От
Lexington Luthor
Дата:
moises wrote:
> Hello,
> 
> I’m new in postgres SQL and I have some questions about the space where 
> postgres process run.
> 
> 1-Can any body say me what libs use postgres for make system calls, for 
> example LIBC?
> 
> 2-Can any body talk me if some postgres process can run in Linux kernel 
> space?
> 
> 3- Some body knows if exist some projects that ports postgres process on 
> Linux kernel space.
>  
> 
> I was read some source code of postgres, like,
> 
> Postgres.C and others…
> 
> I was found C instructions like Printf, that’s prohibitive for Linux 
> kernel applications, for example in kernel mode we use printk.
> 
> I suppose that postgres are ported in a user space only. I’m Ok?
>  
> 
> Thanks
> 
> Moises


You can do it (e.g. http://www.yl.is.s.u-tokyo.ac.jp/~tosh/kml/) but why 
would you want to? PG runs fine in userspace and I can see no particular 
benefit to being in the kernel.

What exactly are you trying to do with it? Are you trying to interface 
PG with some kernel facility?


LL