EX-5.1 2 a2171512zex-5_1.htm EXHIBIT 5.1

EXHIBIT 5.1

[Vinson & Elkins L.L.P. Letterhead]

July 11, 2006

Plains All American Pipeline, L.P.
333 Clay Street, Suite 1600
Houston, Texas 77002

Re:
Merger of Pacific Energy Partners, L.P. with and into Plains All American Pipeline, L.P.

Ladies and Gentlemen:

        We have acted as counsel to Plains All American Pipeline, L.P., a Delaware limited partnership ("Plains"), in connection with the partnership proceedings taken and to be taken relating to the merger of Pacific Energy Partners, L.P., a Delaware limited partnership ("Pacific"), with and into Plains, with Plains being the surviving limited partnership (the "Merger"), and the conversion of each of the common units of Pacific issued and outstanding at the effective time of the Merger (other than those owned by LB Pacific, LP) into 0.77 common units of Plains ("Plains Common Units"). We have also participated in the preparation and filing with the Securities and Exchange Commission under the Securities Act of 1933, as amended, of a registration statement on Form S-4 (the "Registration Statement") relating to the Merger.

        We have examined the Registration Statement, including the joint proxy statement/prospectus that forms a part of the Registration Statement, the Merger Agreement, dated as of June 11, 2006, by and among Plains, Plains AAP, L.P., Plains All American GP, LLC, Pacific, Pacific Energy Management LLC and Pacific Energy GP, LP (the "Merger Agreement"), the Third Amended and Restated Agreement of Limited Partnership of Plains, as amended (the "Partnership Agreement"), the Certificate of Limited Partnership of Plains and such other formation documents and agreements, as we have deemed necessary or appropriate for purposes of this opinion. In addition, we have reviewed certain certificates of officers of the general partner of Plains and of public officials, and we have relied on such certificates with respect to certain factual matters that we have not independently established.

        We are rendering this opinion as of the time the Registration Statement becomes effective in accordance with Section 8(a) of the Securities Act.

        Based on the foregoing, and subject to the assumptions, limitations and qualifications set forth herein, it is our opinion that the Plains Common Units have been duly and validly authorized by all necessary action on the part of Plains and, when issued pursuant to the terms of the Merger Agreement, will be validly issued, fully paid and non-assessable by Plains.

        The opinion expressed herein is limited exclusively to the federal laws of the United States of America and the Revised Uniform Limited Partnership Act of the State of Delaware and the Constitution of the State of Delaware, each as interpreted by the courts of the State of Delaware, and we are expressing no opinion as to the effect of the laws of any other jurisdiction.

        We hereby consent to the references to this firm under the caption "Legal Matters" in the prospectus forming a part of the Registration Statement and to the filing of this opinion as an Exhibit to the Registration Statement. By giving such consent, we do not admit that we are within the category of persons whose consent is required under Section 7 of the Securities Act or the rules and regulations of the Securities and Exchange Commission issued thereunder.

    Very truly yours,

   
    /s/ Vinson & Elkins L.L.P.
Vinson & Elkins L.L.P.