PDA

View Full Version : مبتدی: پیغام خطا بعد از آپلود سایت



bezar_405
یک شنبه 20 فروردین 1391, 21:15 عصر
با سلام خدمت دوستان من اولین باره که سایت توکنترل پنل آپلود می کنم الان با این پیغام خطا مواجه شدم لطفا راهنمایی کنید
من دیتابیس ساختم به اسم:Mahsharالبته خود کنترل پنل یه تکه بهش اضافه کرده به صورت
Database name:studiomahshar.com_Mahshar*

بعد تو قسمت create userیه یوزر تعریف کردم بایوزر نیم:studiomahsharوپسورد*******
که کنترل پنل یه قسمت دیگه بهش اظافه می که به صورتدر میادstudiomahshar.com_studiomahshar

سوالم اینه که آیا تو web.configکانکشن استرینگو اینجودی تعریف کنم درسته البته این خطا هم اگه درست گفته باشم مربوط به همین قسمته.


<connectionStrings>
<add name="Con"
connectionString="data source=(local) ; Database=Mahshar


; User Id=studiomahshar


;Password=sm2223407" />

</connectionStrings>


یا باید اون قسمتهایی که خود کنترل پنل اضافه کرده اونام بنویسم

Server Error in '/' Application.


Login failed for user 'OWNEROR-08IR31B\studiomahsharc_web'.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException: Login failed for user 'OWNEROR-08IR31B\studiomahsharc_web'.

Source Error:


An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:


[SqlException (0x80131904): Login failed for user 'OWNEROR-08IR31B\studiomahsharc_web'.] System.Data.SqlClient.SqlInternalConnection.OnErro r(SqlException exception, Boolean breakConnection) +4856727 System.Data.SqlClient.TdsParser.ThrowExceptionAndW arning(TdsParserStateObject stateObj) +194 System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +1121 System.Data.SqlClient.SqlInternalConnectionTds.Com pleteLogin(Boolean enlistOK) +35 System.Data.SqlClient.SqlInternalConnectionTds.Att emptOneLogin(ServerInfo serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64 timerExpire, SqlConnection owningObject) +144 System.Data.SqlClient.SqlInternalConnectionTds.Log inNoFailover(String host, String newPassword, Boolean redirectedUserInstance, SqlConnection owningObject, SqlConnectionString connectionOptions, Int64 timerStart) +340 System.Data.SqlClient.SqlInternalConnectionTds.Ope nLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance) +225 System.Data.SqlClient.SqlInternalConnectionTds..ct or(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance) +189 System.Data.SqlClient.SqlConnectionFactory.CreateC onnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection) +185 System.Data.ProviderBase.DbConnectionFactory.Creat ePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options) +31 System.Data.ProviderBase.DbConnectionPool.CreateOb ject(DbConnection owningObject) +431 System.Data.ProviderBase.DbConnectionPool.UserCrea teRequest(DbConnection owningObject) +66 System.Data.ProviderBase.DbConnectionPool.GetConne ction(DbConnection owningObject) +499 System.Data.ProviderBase.DbConnectionFactory.GetCo nnection(DbConnection owningConnection) +65 System.Data.ProviderBase.DbConnectionClosed.OpenCo nnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +117 System.Data.SqlClient.SqlConnection.Open() +122 Default4.FetchDataToDataList() +82 Default4.Page_Load(Object sender, EventArgs e) +24 System.Web.Util.CalliHelper.EventArgFunctionCaller (IntPtr fp, Object o, Object t, EventArgs e) +14 System.Web.Util.CalliEventHandlerDelegateProxy.Cal lback(Object sender, EventArgs e) +35 System.Web.UI.Control.OnLoad(EventArgs e) +99 System.Web.UI.Control.LoadRecursive() +50 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627:گریه::گریه::گریه::گریه::گر ه::گریه::گریه::گریه::گریه::گر ه::گریه::گریه:

hamid_shrk
یک شنبه 20 فروردین 1391, 21:23 عصر
یوزری که برای connection string تون توی وب کانفیگ تعریف کردید رو نمیشناسه.
چی گذاشتید تو وب کانفیگ ؟

bezar_405
یک شنبه 20 فروردین 1391, 21:32 عصر
باتوجه به توضیح بالا که دوباره یه مطالبی رو بهش اضافه کردم
این جور نوشتم
<configuration>
<appSettings/>
<connectionStrings>
<add name="Con" connectionString="data source=(local) ; Database=Mahshar
; User Id=studiomahshar
;Password=sm2223407" />
</connectionStrings>

hamid_shrk
یک شنبه 20 فروردین 1391, 21:39 عصر
data source=(local) ؟؟؟
لوکال نباید بذارید ،

Data Source=myServerAddress;Initial Catalog=myDataBase;User Id=myUsername;Password=myPassword;

myServerAddress آدرس سروز شماست که تو پنلتون باید ئنبالش بگردید یا از پشتیبانی بخواید.که 100% تو پنل هست .
این تاپیک رو هم مطالعه بفرمایید تا بهتر بتونید با پنل کار کنید :
http://barnamenevis.org/showthread.php?267021-Upload-%D9%88-%D9%86%D8%B5%D8%A8-%D8%A8%D8%B1%D9%86%D8%A7%D9%85%D9%87-Asp.net-%D9%88-%D9%BE%D8%A7%DB%8C%DA%AF%D8%A7%D9%87-%D8%AF%D8%A7%D8%AF%D9%87-MSSQL-%D8%AF%D8%B1-Host-%28%D8%AF%D8%B1-%D8%AD%D8%A7%D9%84-%D8%AA%DA%A9%D9%85%DB%8C%D9%84%29

hakan648
یک شنبه 20 فروردین 1391, 21:48 عصر
سلام


data source=(local); Database=Mahshar; User Id=studiomahshar; Password=sm2223407; Integrated Security=false;

موفق باشید ...

bezar_405
یک شنبه 20 فروردین 1391, 22:01 عصر
با توجه پاسخ
hamid_shrk
اون قسمتهایی که بالا نوشتم که که خود کنترل پنل اظافه کرده به نظر شما نباید اونمرو اضافه کنم؟
و الان آقال hakan648گفتن که با همون لوکال کنکشن استرینگ اردا نداره وایراد از کدهمام تو وب کانفیگ هستش که من اینجوری اونارو نوشتم


<?xml
version="1.0"?>
<configuration>

<appSettings/>
<connectionStrings>

<add name="Con" connectionString="data source=(local) ; Database=Mahshar



; User Id=studiomahshar


;Password=sm2223407" ;Integrated
Security=false;/>

</connectionStrings>
<system.web>

<customErrors mode="Off"/>

</system.web>



<system.web>

<compilation debug="true" />

<authentication mode="Forms">
<forms
defaultUrl="~/" loginUrl="login.aspx" >

</forms>
</authentication>

</system.web>
<location
path="UserPanel">

<system.web>

<authorization>
<allow
roles="user"></allow>

<deny users="*"/>

</authorization>

</system.web>

</location>
<location
path="AdminPanel">

<system.web>

<authorization>

<allow
roles="Admin"></allow>

<deny users="*"/>

</authorization>



</system.web>


</location>

<system.web>
<httpRuntime
maxRequestLength="51200" enable="true"
executionTimeout="45"/>

</system.web>

</configuration>
مشکل از کجاس خدا می دونه
تو محیط ویژوال استودیو که مشکلی نداره!و کار می کنه







کد آقای hakanroکه اضافه کردم این پیغام خطارو میده
یه نگاه بندازید لطفاwww.studiomahshar.ir (http://www.studiomahshar.ir)