can somebody help me . Will appreciate your support here. 
If possible share me steps i can take to narrow down further. 
>From client browser i can access the server api as well as UI on hitting 
the respective URL's. 
For some reason, no links section displayed when running the app with 
production mode.
 All suggestions followed from common installation issues and fixes 
highlighted in dpsace site . All software / setup versions as per 
recommendation of Dspace 7 docs. 
NODE_EXTRA_CA_CERTS is also set. 
Certificate issued by globalsign . Root certificate expiry is also correct. 
 Anything i can do to get some logs information in Front end to understand 
what causes to fail ? 


On Tuesday, 19 October 2021 at 22:44:42 UTC+5:30 NTech wrote:

> Hi Tim, 
>
> I am just wondering why Front end is unable to hit the backend with SSL . 
> Let me give you detailed info and hope this will help you assist me to 
> solve the issue. 
>
> I am accessing app using VPN from Edge browser. 
>
> *Apache Proxy Configuration is as below *
>
> *<VirtualHost _default_:443>*
>
> *     SSLEngine on*
> *     SSLCertificateFile "C:/Certificate/dspace.crt"  *
> *     SSLCertificateKeyFile "C:/Certificate/dspace-decrypted.key"*
>
>   
> *    ProxyPass /server http://localhost:8080/server 
> <http://localhost:8080/server>*
> *    ProxyPassReverse /server http://localhost:8080/server 
> <http://localhost:8080/server>*
> *    RequestHeader set X-Forwarded-Proto https*
>
> *    ProxyPass / http://localhost:8983/ <http://localhost:8983/>*
> *    ProxyPassReverse / http://localhost:8983/ <http://localhost:8983/>*
> *</VirtualHost>*
>
> *Local.cfg File *
>
> *dspace.server.url = https://lifedam.futuregenerali.in/server 
> <https://lifedam.futuregenerali.in/server>*
> *dspace.ui.url = https://lifedam.futuregenerali.in 
> <https://lifedam.futuregenerali.in>*
>
> *Environment.prod.ts*
>
> *export const environment = {*
> *    ui: {*
> *    ssl: false,*
> *    host: 'localhost',*
> *    port: 8983,*
> *    // NOTE: Space is capitalized because 'namespace' is a reserved 
> string in TypeScript*
> *    nameSpace: '/'*
> *},*
>
> *rest: {*
> *  ssl: true,*
> *  host: 'lifedam.futuregenerali.in <http://lifedam.futuregenerali.in>',*
> *  port: 443,*
> *  // NOTE: Space is capitalized because 'namespace' is a reserved string 
> in TypeScript*
> *  nameSpace: '/server'*
> *}*
> *};*
>
> *Error in Console Developer Tools*
>
> *hal-endpoint.service.ts:42 *
>  *No _links section found at https://lifedam.futuregenerali.in/server/api 
> <https://lifedam.futuregenerali.in/server/api>*
> *(anonymous) @ hal-endpoint.service.ts:42*
>
> Attached the snapshots of browser for front end ,backend, certificate as 
> well as console error. 
>
> Unable to identify the exact problem or what to be troubleshooted further 
> . Please assist.
>
> On Tuesday, 19 October 2021 at 22:11:05 UTC+5:30 Tim Donohue wrote:
>
>> Hi all,
>>
>> Since it sounds like several folks have hit on this thread, I want to 
>> stress that this "no _links section found in production mode" error can be 
>> caused by a *variety of issues​​*.  Unfortunately, this error simply 
>> means that your Frontend cannot communicate with your Backend.
>>
>> Therefore, it may appear in *any of these sorts of scenarios*:
>>
>>    - Configuration issues in the frontend or backend.  Especially check 
>>    "rest" configuration of frontend & the "dspace.ui.url" configuration of 
>> the 
>>    backend.
>>    - SSL certificate expiration or trust issues.  More specifically, if 
>>    the frontend (Node.js) doesn't trust your backend's SSL certificate, this 
>>    may occur. See this StackOverflow on trusting certs in Node.js: 
>>    
>> https://stackoverflow.com/questions/29283040/how-to-add-custom-certificate-authority-ca-to-nodejs
>>   
>>    (This especially can occur if you have a self-signed cert...but is seems 
>>    some folks have also seen this with Lets Encrypt signed certs)
>>    - There is something else blocking access of the frontend to the 
>>    backend...could be a proxy issue, a firewall issue, or even something 
>> else 
>>    blocking the usual access ports (80 for HTTP or 443 for HTTPS).  You 
>> should 
>>    verify the backend can be accessed from the server running your frontend. 
>>    Also verify the backend is accessible to the * client machine*​ you 
>>    are testing from (i.e. from your browser).  *Generally, your backend 
>>    should be publicly accessible on the web*, unless all your users are 
>>    guaranteed to be behind a VPN or similar.
>>    - (Other undiscovered scenarios may also exist...these are just the 
>>    most common)
>>
>> There's unfortunately not a single solution that can solve this problem 
>> 100% of the time.  I wish there was, but this error is a generic error 
>> which provides us with no information about what might be the root cause. 
>>
>> To those of you seeing this error, I think we'd need more information on 
>> this list about your setup to help provide better advice.  Also take a 
>> closer look at other "common installation issues" to verify that none of 
>> them apply to your site: 
>> https://wiki.lyrasis.org/display/DSDOC7x/Installing+DSpace#InstallingDSpace-CommonInstallationIssues
>>
>> Glad to try and offer more advice to folks, but we'd need more 
>> information about your setup on this list before we can help narrow down 
>> the problem. 
>>
>> Tim
>>
>> ------------------------------
>> *From:* [email protected] <[email protected]> on behalf 
>> of NTech <[email protected]>
>> *Sent:* Tuesday, October 19, 2021 11:20 AM
>> *To:* DSpace Technical Support <[email protected]>
>> *Subject:* [dspace-tech] Re: DSPACE7 no _links section found in 
>> production mode 
>>  
>> I am also facing the exact same issue with similar configuration.  
>> Both backend and frontend installed in a windows server. 
>> Using Apache to proxy and SSL. 
>> Generated a new SSL certificate and this shows secure while trying to 
>> access UI/ Backend from browser.  Also additionally added an environment 
>> variable NODE_EXTRA_CA_CERTS pointing to the PEM file 
>> No clue why this fails with SSL certificate . 
>> Everything worked Ok without SSL though.
>> Front End Link to verify <https://lifedam.futuregenerali.in/>
>> Backend Link to verify <https://lifedam.futuregenerali.in/server/>
>>
>> Please help.
>>
>>
>> On Tuesday, 12 October 2021 at 22:15:38 UTC+5:30 Tim Donohue wrote:
>>
>> This issue is puzzling to me, as it sounds like it should work.
>>
>> It makes me wonder if there's a possible SSL Certificate "trust" 
>> issue....where the frontend (running on Node.js) is not *trusting* the SSL 
>> Certificate that your backend is returning.  We *have* seen this before, 
>> but in the past it was always with a self-signed SSL Cert.  We have a 
>> couple of general notes on a workaround here: 
>> https://wiki.lyrasis.org/display/DSDOC7x/Installing+DSpace#InstallingDSpace-UsingaSelf-SignedSSLCertificatecausestheFrontendtonotbeabletoaccesstheBackend
>>  
>>
>> However, I admit, I'm not 100% sure if this is the issue.
>>
>> As a sidenote, per Mohammed's site, I've tried updating my local copy of 
>> Angular UI (running the latest code) by just updating one line of my 
>> "environment.common.ts" file to say "host: 'dspace.uobaghdad.edu.iq'".  
>> I've then run "yarn start", and my UI comes up on http://localhost:4000/ 
>> displaying the public content available at 
>> https://dspace.uobaghdad.edu.iq/server/.   So, I cannot even reproduce 
>> this "no _links section" error if I run in production mode locally.
>>
>> I'm a bit confused what could be going on, but it seems like it might be 
>> an SSL cert trust issue or it might be a configuration error.  Have you 
>> also double checked you are running a supported version of Node.js and 
>> Yarn? 
>> https://wiki.lyrasis.org/display/DSDOC7x/Installing+DSpace#InstallingDSpace-InstallingtheFrontend(UserInterface)
>>  
>>
>> Tim
>>
>> On Monday, October 11, 2021 at 5:06:58 AM UTC-5 [email protected] wrote:
>>
>> Hi Mohammed,
>> you have exactly the same problem.
>> Jan
>>
>> On Monday, October 11, 2021 at 11:43:55 AM UTC+2 Mohammed Al-Shammaa 
>> wrote:
>>
>> Hi, 
>> I have installed DSpace 7 successfully, and it was working fine, however, 
>> suddenly it is giving the "No _links section found" error. I tried to "yarn 
>> start" and it was run without any errors:
>>
>> Building production environment
>> Angular environment.ts file generated correctly at 
>> ./src/environments/environment.ts
>>
>> but the problem still exists.
>>
>> https://dspace.uobaghdad.edu.iq/
>>
>> Any help to solve this issue is really appreciated.
>>
>> On Monday, 11 October 2021 at 12:19:05 UTC+3 [email protected] wrote:
>>
>> To Tim: perhaps I can let you enter on our virtual machine if you agree
>> Jan
>>
>> On Monday, October 11, 2021 at 11:15:08 AM UTC+2 Jan Broulím wrote:
>>
>> Dear Joel,
>> I tried different certification authority, but it did not help. DSpace 
>> still works only in dev mode.
>> But somehow it can be connected - when I was testing it on 2 machines 
>> without SSL, it was working properly.
>> Thanks
>> Jan
>>
>> On Friday, October 8, 2021 at 1:43:05 PM UTC+2 [email protected] wrote:
>>
>> Jan and Tim,
>>
>> I'm going to offer some extra information that might help future people. 
>> I was (am) testing this on a development server with self-signed TLS 
>> certificates and that was also causing this error to occur. Since  am on a 
>> development server, I switched everything to SSL=false, and HTTP instead of 
>> HTTPS and that mostly solved the problems I was having. I will pursue the 
>> problem later, but I may need to add my organization's internal Root CA 
>> Certificate to my development server and continue testing.
>>
>> Of course I had to update all of my settings to match (local.cfg, 
>> environment.dev.ts, etc)
>>
>> I don't think a LetsEncrypt Cert would cause this problem, but you never 
>> know.
>>
>> --Joel Richard
>> Smithsonian Libraries and Archives
>>
>> On Monday, October 4, 2021 at 1:08:06 PM UTC-4 [email protected] wrote:
>>
>> Hi Tim,
>>
>> the files are identical (I also tried a copy of environment.dev.ts to 
>> environment.prod.ts), which did not help.
>>
>> It looks very strange for me, the guide 
>> https://wiki.lyrasis.org/display/DSDOC7x/Installing+DSpace#InstallingDSpace-%22No_linkssectionfoundat...%22errorfromUserInterface
>>  
>> probably will be useful. 
>>
>> Installed on Debian.
>>
>> Jan
>>
>>
>> On Monday, October 4, 2021 at 5:32:04 PM UTC+2 Tim Donohue wrote:
>>
>> Hi Jan,
>>
>> We have a guide for that error here: 
>> https://wiki.lyrasis.org/display/DSDOC7x/Installing+DSpace#InstallingDSpace-%22No_linkssectionfoundat...%22errorfromUserInterface
>>
>> That said, your REST API at https://sulis53.zcu.cz/server/ "looks 
>> correct" to me, and you can see that it has a "_links" section in the 
>> response.
>>
>> Therefore, I highly suspect something is wrong with your 
>> environment.prod.ts.  Are you SURE it's identical  to environment.dev.ts?  
>> Maybe there's a stray comma or odd space or something that is causing 
>> issues when the configuration is read by `yarn start`?   When `yarn start` 
>> runs, does it say it's using environment.prod.ts, or does it have a message 
>> like "No specific environment file found..."  (if it's the latter, that 
>> means it's having issues reading your environment.prod.ts)
>>
>> It's not immediately obvious to me what the problem is...which is why I 
>> immediately suspect it might be an invalid config file or similar.
>>
>> If you are able to figure out the problem, please do let us know. That 
>> way we can also update our guide about other issues that might cause this 
>> "No _links section found" error. 
>>
>> Tim
>>
>> On Monday, October 4, 2021 at 10:23:09 AM UTC-5 [email protected] wrote:
>>
>> Hello,
>>
>> we are installing DSpace7 and unfortunately have problems, which we are 
>> not able to explain or even resolve.
>>
>> Environment file and apache configuration is attached below.
>>
>> When running "yarn start:dev", it seems to be working, but when running 
>> "yarn start" (environment.prod.ts and environment.dev.ts are the same), we 
>> always get "no _links section found..." error.
>>
>> Could you please help us to resolve the problem? What might be the 
>> difference, which can cause this problem?
>>
>> You can even check - "No _links section found at 
>> https://sulis53.zcu.cz/server/api";, but this link is normally accessible.
>> The testing instance runs here: https://sulis53.zcu.cz:
>>
>> Thank you
>>
>> With regards
>>
>> Jan
>>
>>
>> -------------------------------
>> environment.*.ts:
>>
>> export const environment = {
>>   ui: {
>>       ssl: false,
>>       host: 'localhost',
>>       port: 4000,
>>       nameSpace: '/'
>>   },
>>   rest: {
>>       ssl: true,
>>       host: 'sulis53.zcu.cz',
>>       port: 443,
>>       nameSpace: '/server'
>>   }
>> };
>>
>>
>> apache:
>> <VirtualHost _default_:443>
>>     SSLEngine on
>>     SSLCertificateFile /etc/letsencrypt/live/sulis53.zcu.cz/cert.pem
>>     SSLCertificateKeyFile /etc/letsencrypt/live/
>> sulis53.zcu.cz/privkey.pem
>>
>>     ProxyPass /server http://localhost:8080/server
>>     ProxyPassReverse /server http://localhost:8080/server
>>
>>     RequestHeader set X-Forwarded-Proto https
>>
>>     ProxyPass / http://localhost:4000/
>>     ProxyPassReverse / http://localhost:4000/
>>
>> </VirtualHost>
>>
>> -- 
>> All messages to this mailing list should adhere to the Code of Conduct: 
>> https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "DSpace Technical Support" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected].
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/dspace-tech/b5058605-34c0-4d68-9072-1ca4d76bf710n%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/dspace-tech/b5058605-34c0-4d68-9072-1ca4d76bf710n%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
All messages to this mailing list should adhere to the Code of Conduct: 
https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx
--- 
You received this message because you are subscribed to the Google Groups 
"DSpace Technical Support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dspace-tech/931bbe5a-16db-44d2-b172-068cab5a18b7n%40googlegroups.com.

Reply via email to